[Solved] Can a nested/inner class see the private members of its containing/outer class?


A nested Class has access to the private Members of it’s containing type:

Class T{
    private static void Foo(){
       // do sth.
    }

    public class InnerClass{
       public static void Bar(){
          Foo(); //no Problem.
       }
    }
}

1

solved Can a nested/inner class see the private members of its containing/outer class?