Package org.eclipse.epsilon.epl.dom
Class Role
- java.lang.Object
-
- org.eclipse.epsilon.common.module.AbstractModuleElement
-
- org.eclipse.epsilon.epl.dom.Role
-
- All Implemented Interfaces:
ModuleElement
public class Role extends AbstractModuleElement
-
-
Field Summary
Fields Modifier and Type Field Description protected ExecutableBlock<java.lang.Boolean>
activeAst
protected Cardinality
cardinality
protected Domain
domain
protected ExecutableBlock<java.lang.Boolean>
guard
protected java.lang.Boolean
isActiveCache
protected java.util.List<java.lang.String>
names
protected boolean
negative
protected ExecutableBlock<java.lang.Boolean>
optionalAst
protected EolType
type
protected TypeExpression
typeExpression
-
Constructor Summary
Constructors Constructor Description Role()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
build(AST cst, IModule module)
Cardinality
getCardinality()
Domain
getDomain()
ExecutableBlock<java.lang.Boolean>
getGuard()
java.util.List<java.lang.String>
getNames()
EolType
getType(IEolContext context)
boolean
hasActiveAst()
boolean
isActive(IEolContext context)
boolean
isActive(IEolContext context, boolean forceRecompute)
boolean
isNegative()
boolean
isOptional(IEolContext context)
-
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
-
names
protected java.util.List<java.lang.String> names
-
typeExpression
protected TypeExpression typeExpression
-
domain
protected Domain domain
-
type
protected EolType type
-
guard
protected ExecutableBlock<java.lang.Boolean> guard
-
optionalAst
protected ExecutableBlock<java.lang.Boolean> optionalAst
-
activeAst
protected ExecutableBlock<java.lang.Boolean> activeAst
-
cardinality
protected Cardinality cardinality
-
negative
protected boolean negative
-
isActiveCache
protected java.lang.Boolean isActiveCache
-
-
Method Detail
-
build
public void build(AST cst, IModule module)
- Specified by:
build
in interfaceModuleElement
- Overrides:
build
in classAbstractModuleElement
-
getCardinality
public Cardinality getCardinality()
-
hasActiveAst
public boolean hasActiveAst()
-
isActive
public boolean isActive(IEolContext context) throws EolRuntimeException
- Throws:
EolRuntimeException
-
isActive
public boolean isActive(IEolContext context, boolean forceRecompute) throws EolRuntimeException
- Throws:
EolRuntimeException
-
isOptional
public boolean isOptional(IEolContext context) throws EolRuntimeException
- Throws:
EolRuntimeException
-
isNegative
public boolean isNegative()
-
getNames
public java.util.List<java.lang.String> getNames()
-
getDomain
public Domain getDomain()
-
getGuard
public ExecutableBlock<java.lang.Boolean> getGuard()
-
getType
public EolType getType(IEolContext context) throws EolRuntimeException
- Throws:
EolRuntimeException
-
-