Java外部类(非静态)访问内部类(静态/非静态)
public class OutClass {
public int a1 = 1;
public static int b1 = 1;
public void outerConMethod(){
System.out.println("外部类的普通方法!");
getInstance().instanceConMethod();
a1 = getInstance().b2;
getInstance().a2 = 3;
instanceInnerClass inner1 = new instanceInnerClass();
inner1.instanceConMethod();
OutClass.instanceInnerClass inner2 = new OutClass.instanceInnerClass();
inner2.instanceConMethod();
staticInnerClass.innerStaticMethod();
System.out.println(staticInnerClass.b3);
OutClass.staticInnerClass staticInner1 = new OutClass.staticInnerClass();
staticInner1.InnerConMethod();
System.out.println(staticInner1.a3);