方法内部类 怎么访问 该方法里的同名变量?
public class T3 {
public void showInner() {
int i = 52;
int s = 0;
class InnerClass {
private int s = 325;
private void showInnerClass() {
System.out.println("方法内部类使用:"+ ??? );
System.out.println("此处我改如何获得 i 的值" + i);
}
}
public class T3 {
public void showInner() {
int i = 52;
int s = 0;
class InnerClass {
private int s = 325;
private void showInnerClass() {
System.out.println("方法内部类使用:"+ ??? );
System.out.println("此处我改如何获得 i 的值" + i);
}
}
2017-01-19
举报