Why would you use a nested class over an outer class?

Static Nested Class : can’t access enclosing class instance and invoke methods on it, so should be used when the nested class doesn’t require access to an instance of the enclosing class . A common use of static nested class is to implement a components of the outer object .

Sizin İçin Seçtik  Yari kamusal mal ve hizmetler nedir?

Leave a Reply

Your email address will not be published. Required fields are marked *