|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.elca.el4j.util.metadata.annotations.Annotations
public class Annotations
Helper class to get annotations of a field, method, and class. Annotations can also fetched filtered.
Constructor Summary | |
---|---|
Annotations()
|
Method Summary | |
---|---|
protected Collection |
filter(Collection c,
Class filter)
Filters the given collection. |
Collection |
getAttributes(Class targetClass)
Return the class attributes of the target class. |
Collection |
getAttributes(Class targetClass,
Class filter)
Return the class attributes of the target class of a given type. |
Collection |
getAttributes(Field targetField)
Return the field attributes of the target field. |
Collection |
getAttributes(Field targetField,
Class filter)
Return the field attributes of the target method of a given type. |
Collection |
getAttributes(Method targetMethod)
Return the method attributes of the target method. |
Collection |
getAttributes(Method targetMethod,
Class filter)
Return the method attributes of the target method of a given type. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Annotations()
Method Detail |
---|
public Collection getAttributes(Class targetClass)
getAttributes
in interface Attributes
targetClass
- the class that contains attribute information
null
public Collection getAttributes(Method targetMethod)
getAttributes
in interface Attributes
targetMethod
- the method that contains attribute information
null
public Collection getAttributes(Field targetField)
getAttributes
in interface Attributes
targetField
- the field that contains attribute information
null
public Collection getAttributes(Class targetClass, Class filter)
The class attributes are filtered by providing a Class
reference to indicate the type to filter on. This is useful if you know
the type of the attribute you are looking for and don't want to sort
through the unfiltered Collection yourself.
getAttributes
in interface Attributes
targetClass
- the class that contains attribute informationfilter
- specify that only this type of class should be returned
public Collection getAttributes(Method targetMethod, Class filter)
The method attributes are filtered by providing a Class
reference to indicate the type to filter on. This is useful if you know
the type of the attribute you are looking for and don't want to sort
through the unfiltered Collection yourself.
getAttributes
in interface Attributes
targetMethod
- the method that contains attribute informationfilter
- specify that only this type of class should be returned
null
public Collection getAttributes(Field targetField, Class filter)
The field attributes are filtered by providing a Class
reference to indicate the type to filter on. This is useful if you know
the type of the attribute you are looking for and don't want to sort
through the unfiltered Collection yourself.
getAttributes
in interface Attributes
targetField
- the field that contains attribute informationfilter
- specify that only this type of class should be returned
null
protected Collection filter(Collection c, Class filter)
c
- Is the collection to filter.filter
- Is the class used for filtering.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |