Skip to content
Snippets Groups Projects
Commit 0c7de485 authored by Simon Barner's avatar Simon Barner
Browse files

- Document that getAnnotation(IModelElement modelElement, Class<T> clazz)...

- Document that getAnnotation(IModelElement modelElement, Class<T> clazz) wraps the model access into a command
refs 2199,1841
parent 7d732426
No related branches found
No related tags found
No related merge requests found
......@@ -68,9 +68,18 @@ public class AnnotationUtils {
}
/**
* <p>
* Returns the annotation of a given {@code Class<T>} from a given {@code modelElement}. If the
* annotation does not exist yet, it is created and added to the specification list of the
* {@code modelElement}.
* </p>
*
* <p>
* <b>Note: </b>The access to the model is wrapped into a command in order to allow for
* transparent creation of the annotation object from other contexts (e.g., GUI). If this is not
* desirable, use the {@link #getAnnotation(IModelElement, Class, boolean)} variant of this
* method.
* </p>
*/
public static <T extends IAnnotatedSpecification> T getAnnotation(IModelElement modelElement,
Class<T> clazz) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment