Package org.nuiton.eugene.java.extension
Class AnnotationsManager
- java.lang.Object
-
- org.nuiton.eugene.java.extension.AnnotationsManager
-
public class AnnotationsManager extends Object
To manage annotations for anyObjectModelElement
of a classifier. Created: 17 déc. 2009- Since:
- 2.0.0
- Author:
- Tony Chemit - chemit@codelutin.com
-
-
Field Summary
Fields Modifier and Type Field Description protected Map<ObjectModelElement,List<ObjectModelAnnotation>>
annotations
-
Constructor Summary
Constructors Constructor Description AnnotationsManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAnnotation(ObjectModelElement element, ObjectModelAnnotation annotation)
Add theannotation
for the givenelement
of the classifier.protected Map<ObjectModelElement,List<ObjectModelAnnotation>>
getAnnotations()
List<ObjectModelAnnotation>
getAnnotations(ObjectModelElement element)
Obtain the array of annotations registred for a given element of the classifier.
-
-
-
Field Detail
-
annotations
protected Map<ObjectModelElement,List<ObjectModelAnnotation>> annotations
-
-
Method Detail
-
addAnnotation
public void addAnnotation(ObjectModelElement element, ObjectModelAnnotation annotation)
Add theannotation
for the givenelement
of the classifier.- Parameters:
element
- the element where to register the annotationannotation
- the annotation to register
-
getAnnotations
public List<ObjectModelAnnotation> getAnnotations(ObjectModelElement element)
Obtain the array of annotations registred for a given element of the classifier.- Parameters:
element
- the element where to search for annotations- Returns:
- the annotations for the element (empty arry if none found
-
getAnnotations
protected Map<ObjectModelElement,List<ObjectModelAnnotation>> getAnnotations()
-
-