Types of Annotations
suggest changeThere are three types of annotations.
- Marker Annotation - annotation that has no method
@interface CustomAnnotation {}
- Single-Value Annotation - annotation that has one method
@interface CustomAnnotation { int value(); }
- Multi-Value Annotation - annotation that has more than one method
@interface CustomAnnotation{ int value1(); String value2(); String value3(); }
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents