public class XAnnotation extends Object
Modifier and Type | Field and Description |
---|---|
static XAnnotation[] |
EMPTY_ARRAY
Empty array of annotations.
|
Constructor and Description |
---|
XAnnotation(Class<? extends Annotation> annotationClass,
XAnnotationField<?>... fields)
Constructs an xannotation for the given annotation class.
|
Modifier and Type | Method and Description |
---|---|
<T> T |
accept(XAnnotationVisitor<T> visitor)
Accepts the annotation visitor.
|
boolean |
equals(Object obj) |
Class<? extends Annotation> |
getAnnotationClass()
Returns the annotation class.
|
List<XAnnotationField<?>> |
getFieldsList()
Returns the list of the fields.
|
Map<String,XAnnotationField<?>> |
getFieldsMap()
Returns the map of the fields.
|
Annotation |
getResult()
Returns the instance of the annotation for this xannotation.
|
int |
hashCode() |
String |
toString() |
public static XAnnotation[] EMPTY_ARRAY
public XAnnotation(Class<? extends Annotation> annotationClass, XAnnotationField<?>... fields) throws IllegalArgumentException
annotationClass
- annotation class, must not be null
fields
- fields of the xannotation.IllegalArgumentException
- If annotation class is null
, some required
annotation fields are missing or some annotation fields have
mismatching types.public Class<? extends Annotation> getAnnotationClass()
public List<XAnnotationField<?>> getFieldsList()
public Map<String,XAnnotationField<?>> getFieldsMap()
public Annotation getResult()
public <T> T accept(XAnnotationVisitor<T> visitor)
T
- Visitor result type.visitor
- visitor.Copyright © 2006–2015 Highsource. All rights reserved.