ua.gradsoft.javachecker.models
Class JavaAnnotationInstanceModel
java.lang.Object
ua.gradsoft.javachecker.models.JavaAnnotationInstanceModel
- Direct Known Subclasses:
- JavaAnnotationDefaultInstanceModel, JavaClassAnnotationInstanceModel, JavaDelegatedAnnotationInstanceModel, JavaTermAnnotationInstanceModel
public abstract class JavaAnnotationInstanceModel
- extends java.lang.Object
Instance of annotation.
- Author:
- rssh
|
Field Summary |
protected java.lang.annotation.ElementType |
elementType_
|
protected java.lang.Object |
target_
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
elementType_
protected java.lang.annotation.ElementType elementType_
target_
protected java.lang.Object target_
JavaAnnotationInstanceModel
protected JavaAnnotationInstanceModel(java.lang.annotation.ElementType et,
java.lang.Object target)
getAnnotationModel
public abstract JavaTypeModel getAnnotationModel()
throws TermWareException,
EntityNotFoundException
- Throws:
TermWareException
EntityNotFoundException
getRetentionPolicy
public java.lang.annotation.RetentionPolicy getRetentionPolicy()
throws TermWareException
- Throws:
TermWareException
getTargetElementType
public java.lang.annotation.ElementType getTargetElementType()
getTargetTypeModel
public JavaTypeModel getTargetTypeModel()
throws InvalidAnnotationTargetElementTypeException
- Returns:
- typeModel, for which annotation is bound.
defined only if target of this annotation is type,
otherwise throw InvalidAnnotationTargetType
- Throws:
InvalidAnnotationTargetElementTypeException
getTargetMethodModel
public JavaMethodModel getTargetMethodModel()
throws InvalidAnnotationTargetElementTypeException
- Throws:
InvalidAnnotationTargetElementTypeException
getTargetFieldModel
public JavaMemberVariableModel getTargetFieldModel()
throws InvalidAnnotationTargetElementTypeException
- Throws:
InvalidAnnotationTargetElementTypeException
getTargetConstructorModel
public JavaConstructorModel getTargetConstructorModel()
throws InvalidAnnotationTargetElementTypeException
- Throws:
InvalidAnnotationTargetElementTypeException
getTargetAnnotationTypeModel
public JavaTypeModel getTargetAnnotationTypeModel()
throws InvalidAnnotationTargetElementTypeException
- Throws:
InvalidAnnotationTargetElementTypeException
getTargetLocalVariableModel
public JavaLocalVariableModel getTargetLocalVariableModel()
throws InvalidAnnotationTargetElementTypeException
- Throws:
InvalidAnnotationTargetElementTypeException
getTargetFormalParameterModel
public JavaTermFormalParameterModel getTargetFormalParameterModel()
throws InvalidAnnotationTargetElementTypeException
- Throws:
InvalidAnnotationTargetElementTypeException
hasElement
public abstract boolean hasElement(java.lang.String elementName)
throws TermWareException
- true, if element whith name
elementName is
provided in this annotation
- Throws:
TermWareException
getElement
public abstract JavaExpressionModel getElement(java.lang.String elementName)
throws NotSupportedException,
TermWareException
- expression, which is defined in annotations.
- Throws:
NotSupportedException
TermWareException
getElements
public abstract java.util.Map<java.lang.String,JavaExpressionModel> getElements()
throws TermWareException
- Map, which contains declared fields.
- Throws:
TermWareException
getModelTerm
public abstract Term getModelTerm()
throws TermWareException,
EntityNotFoundException
- Throws:
TermWareException
EntityNotFoundException