what's the meaning of "this.this$0"?
android, java
Solution
this.this$0 it's same to Main.access$0 These mysterious symbols usually correspond to the anonymous inner classes. The Java VM doesn't know about them, only about top-level classes, so the Java compiler provides several workarounds to make inner classes to work.
Local class has implicit reference to the instance of its enclosing class,'this$0' corresponds to this reference in the decompiled code. JVM prevents classes from accessing privates methods of other classes so the compiler generates several synthetic package-private methods like access$0 in order to access private methods of enclosing instance.
There are many others features of the Java language that are implemented with synthetic methods like generics and covariant return types.
I suggest you to check those links: Decoding Decompiled Source Code For Android
and : Performance Tips
Problem
what's the meaning of "this.this$0" in this code? what does it stands for? I know why we use "this" but I have no idea about "this.this$0" ``` class MainActivity$1 implements TextWatcher { public void afterTextChanged(Editable paramEditable) { } public void beforeTextChanged(CharSequence paramCharSequence, int paramInt1, int paramInt2, int paramInt3) { } public void onTextChanged(CharSequence paramCharSequence, int paramInt1, int paramInt2, int paramInt3) { this.this$0.ChangeToNumber(paramCharSequence.toString()); } } -----------------------or ---------------------- class MainActivity$2 implements View.OnClickListener { public void onClick(View paramView) { this.this$0.startActivity(new Intent(this.this$0, about.class)); } } ```