Created
August 21, 2013 09:46
-
-
Save Ribesg/6292496 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class TestClass { | |
public void method() { | |
// 1 | |
} | |
public void someOtherMethod() { | |
new Runnable() { | |
@Override | |
public void run() { | |
this.method(); // Refers to 2 | |
method(); // Refers to 2, too | |
TestClass.this.method(); // Refers to 1 ! | |
} | |
public void method() { | |
// 2 | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment