com.fasterxml.classmate
Class Annotations
java.lang.Object
com.fasterxml.classmate.Annotations
public class Annotations
- extends Object
Container class used for storing set of annotations resolved for types (classes)
as members (methods, fields, constructors).
- Author:
- tatu
Method Summary |
void |
add(Annotation override)
Method for adding specified annotation, overriding existing value
for the annotation type. |
void |
addAll(Annotations overrides)
Method for adding all annotations from specified set, as overrides
to annotations this set has |
void |
addAsDefault(Annotation defValue)
Method for adding specified annotation if and only if no value
exists for the annotation type. |
|
get(Class<A> cls)
|
int |
size()
|
String |
toString()
|
_annotations
protected HashMap<Class<? extends Annotation>,Annotation> _annotations
Annotations
public Annotations()
add
public void add(Annotation override)
- Method for adding specified annotation, overriding existing value
for the annotation type.
addAll
public void addAll(Annotations overrides)
- Method for adding all annotations from specified set, as overrides
to annotations this set has
addAsDefault
public void addAsDefault(Annotation defValue)
- Method for adding specified annotation if and only if no value
exists for the annotation type.
size
public int size()
get
public <A extends Annotation> A get(Class<A> cls)
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2011 fasterxml.com. All Rights Reserved.