![]() From the Java Language Specification: An annotation type element may have a default value specified for it. A class that implements an interface must implement all the methods declared in the interface. Regarding the default statement in particular: This is used because annotations and interfaces cant have constructors, so this is the only way to have a default value for an annotation attribute. It provides total abstraction means all the methods in an interface are declared with the empty body, and all the fields are public, static and final by default.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |