Skip to content

Instantly share code, notes, and snippets.

View nhoxbypass's full-sized avatar
🐧
I come from Earth

Tam H. Doan nhoxbypass

🐧
I come from Earth
View GitHub Profile
// access modifiers, accessors và constructors được bỏ qua cho ngắn gọn
class IceTeaVietDeveloper implements Parcelable {
String name;
int yearsOfExperience;
List skillSet;
float favoriteFloat;
IceTeaVietDeveloper(Parcel in) {
this.name = in.readString();
private void Form1_Load(object sender, EventArgs e)
{
// Lấy file ảnh từ ổ cứng
// File ảnh phải có trong thư mục debug của solution
// Nếu không chương trình sẽ bị crash vì không tìm thấy file
// Có thể để đường dẫn tuyệt đối đến file ảnh
//(bao gồm cả ổ đĩa, thư mục,...)
Image image = Image.FromFile("BeigeMonitor1.png");
// Thiết lập thuộc tính của PictureBox
private void Form1_Load(object sender, EventArgs e)
{
// Chèn ảnh từ ổ cứng trực tiếp bằng thuộc tính ImageLocation
// Thiết lập thuộc tính Size một cách tự động
pictureBox1.ImageLocation = "BeigeMonitor1.png";
pictureBox1.SizeMode = PictureBoxSizeMode.StretchImage;
}
private void button1_Click(object sender, EventArgs e)
{
// Show hộp thoại open file ra
// Nhận kết quả trả về qua biến kiểu DialogResult
DialogResult result = openFileDialog1.ShowDialog();
//Kiểm tra xem người dùng đã chọn file chưa
if(result == DialogResult.OK)
{
// Gán ....
namespace Picture_Viewer
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
// Cài đặt thuộc tính pictureBox
pictureBox1.ImageLocation = "http://1.bp.blogspot.com/-ZskeiTa6Rig/VZwjEuEQPqI/AAAAAAAAAM0/VK5Im7Cfu3s/s1600/cooltext125983511023412.png";
Network
- HTTPS vs HTTP
- HSTS
- HTTP/2
- Session vs Cookie
- SSL
- SSH
- Symmetric vs Asymmetric
- RSA, RC4, MD5
- AES, DES
ADB
1- Go to your platform-tools folder in a command prompt
2- Enter the command adb devices to get the list of your devices
C:\Android\adt-bundle-windows-x86_64\sdk\platform-tools>adb devices
List of devices attached
emulator-xxxx device
3- Connect a shell to your device:
C:\Android\adt-bundle-windows-x86_64\sdk\platform-tools>adb -s emulator-xxxx shell
4a- You can bypass this step on rooted device
{
"project_info": {
"project_number": "",
"project_id": ""
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:123456789012:android:1234567890123456",
"android_client_info": {
android {
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
testCoverageEnabled true
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules-debug.pro'
def build_param = "${build}"
if (build_param == "devCI") {
// Exclude all except mockDebug flavor
android.variantFilter { variant ->
if (variant.getFlavors().get(0).name != 'mock' || variant.buildType.name != 'debug') {
variant.setIgnore(true)
}
}
} else if (build_param == "releaseCI") {
// Exclude all except prodRelease flavor