Package org.eclipse.epsilon.eol.dom
Class AnnotatableModuleElement
- java.lang.Object
-
- org.eclipse.epsilon.common.module.AbstractModuleElement
-
- org.eclipse.epsilon.eol.dom.AnnotatableModuleElement
-
- All Implemented Interfaces:
ModuleElement
- Direct Known Subclasses:
Column
,ConstraintContext
,DatasetRule
,FlockConstruct
,Grid
,NamedRule
,NestedFrom
,Operation
,Properties
,Reference
public abstract class AnnotatableModuleElement extends AbstractModuleElement
-
-
Field Summary
Fields Modifier and Type Field Description protected AnnotationBlock
annotationBlock
-
Constructor Summary
Constructors Constructor Description AnnotatableModuleElement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
accept(IEolVisitor visitor)
void
build(AST cst, IModule module)
Annotation
getAnnotation(java.lang.String name)
AnnotationBlock
getAnnotationBlock()
protected java.util.List<Annotation>
getAnnotations(java.lang.String name)
java.util.List<java.lang.Object>
getAnnotationsValues(java.lang.String name, IEolContext context)
boolean
getBooleanAnnotationValue(java.lang.String name, IEolContext context)
boolean
getBooleanAnnotationValue(java.lang.String name, IEolContext context, boolean ifNotExists, boolean ifNoValue)
boolean
getBooleanAnnotationValue(java.lang.String name, IEolContext context, java.util.function.Supplier<? extends Variable[]> variables)
boolean
getBooleanAnnotationValue(java.lang.String name, IEolContext context, Variable... variables)
boolean
hasAnnotation(java.lang.String name)
void
setAnnotationBlock(AnnotationBlock annotationBlock)
-
Methods inherited from class org.eclipse.epsilon.common.module.AbstractModuleElement
equals, getChildren, getComments, getData, getDebugInfo, getFile, getModule, getParent, getRegion, getUri, hashCode, setModule, setParent, setRegion, setUri, toString
-
-
-
-
Field Detail
-
annotationBlock
protected AnnotationBlock annotationBlock
-
-
Method Detail
-
getAnnotationBlock
public AnnotationBlock getAnnotationBlock()
-
setAnnotationBlock
public void setAnnotationBlock(AnnotationBlock annotationBlock)
-
build
public void build(AST cst, IModule module)
- Specified by:
build
in interfaceModuleElement
- Overrides:
build
in classAbstractModuleElement
-
hasAnnotation
public boolean hasAnnotation(java.lang.String name)
-
getAnnotations
protected java.util.List<Annotation> getAnnotations(java.lang.String name)
-
getAnnotation
public Annotation getAnnotation(java.lang.String name)
-
getBooleanAnnotationValue
public boolean getBooleanAnnotationValue(java.lang.String name, IEolContext context) throws EolRuntimeException
- Throws:
EolRuntimeException
-
getBooleanAnnotationValue
public boolean getBooleanAnnotationValue(java.lang.String name, IEolContext context, boolean ifNotExists, boolean ifNoValue) throws EolRuntimeException
- Throws:
EolRuntimeException
-
getBooleanAnnotationValue
public boolean getBooleanAnnotationValue(java.lang.String name, IEolContext context, Variable... variables) throws EolRuntimeException
- Parameters:
name
-context
-variables
-- Returns:
- Throws:
EolRuntimeException
- Since:
- 1.6
-
getBooleanAnnotationValue
public boolean getBooleanAnnotationValue(java.lang.String name, IEolContext context, java.util.function.Supplier<? extends Variable[]> variables) throws EolRuntimeException
- Parameters:
name
-context
-variables
-- Returns:
- Throws:
EolRuntimeException
- Since:
- 1.6
-
getAnnotationsValues
public java.util.List<java.lang.Object> getAnnotationsValues(java.lang.String name, IEolContext context) throws EolRuntimeException
- Throws:
EolRuntimeException
-
accept
public void accept(IEolVisitor visitor)
-
-