Package org.eclipse.epsilon.egl.dom
Class GenerationRule
- All Implemented Interfaces:
ModuleElement
,IExecutableModuleElement
,IExecutableModuleElementParameter
- Direct Known Subclasses:
LazyEgxModule.LazyGenerationRule
public class GenerationRule
extends ExtensibleNamedRule
implements IExecutableModuleElementParameter, IExecutableModuleElement
-
Field Summary
Modifier and TypeFieldDescriptionprotected ExecutableBlock<Boolean>
protected ExecutableBlock<Collection<?>>
protected ExecutableBlock<Formatter>
protected ExecutableBlock<Boolean>
protected ExecutableBlock<Boolean>
protected ExecutableBlock<Boolean>
protected ExecutableBlock<EolMap<String,
?>> protected ExecutableBlock<Boolean>
protected ExecutableBlock<?>
protected ExecutableBlock<?>
protected Parameter
protected ExecutableBlock<String>
protected ExecutableBlock<String>
Fields inherited from class org.eclipse.epsilon.erl.dom.ExtensibleNamedRule
allSuperRules, isAbstract, isGreedy, isLazy, isParallel, ofKindCache, ofTypeCache, superRules, superRulesIdentifiers
Fields inherited from class org.eclipse.epsilon.erl.dom.NamedRule
nameExpression
Fields inherited from class org.eclipse.epsilon.eol.dom.AnnotatableModuleElement
annotationBlock
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
accept
(IEgxVisitor visitor) void
execute
(IEolContext context) execute
(IEolContext context_, Object element) Collection<?>
getAllElements
(IEolContext context) ExecutableBlock<? extends Collection<?>>
getOwningModelForType
(IEolContext context) Gets the model which the "transform" parameter type expression belongs to.getSuperRulesAst
(AST cst) Gets the parameter bound to the "transform" part, ifhasTransformSource()
== true.boolean
Used to determine whether this rule operates over a collection of model elements.toString()
Methods inherited from class org.eclipse.epsilon.erl.dom.ExtensibleNamedRule
calculateSuperRules, calculateSuperRules, getAllInstances, getAllOfKind, getAllOfType, getAllSuperRules, getRuleByName, getSuperRules, isAbstract, isGreedy, isLazy, isParallel
Methods inherited from class org.eclipse.epsilon.erl.dom.NamedRule
equals, getName, getNameAst, getNameExpression, hashCode
Methods inherited from class org.eclipse.epsilon.eol.dom.AnnotatableModuleElement
accept, getAnnotation, getAnnotationBlock, getAnnotations, getAnnotationsValues, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, hasAnnotation, setAnnotationBlock
Methods inherited from class org.eclipse.epsilon.common.module.AbstractModuleElement
getChildren, getComments, getData, getDebugInfo, getFile, getModule, getParent, getRegion, getUri, setModule, setParent, setRegion, setUri
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.eclipse.epsilon.common.module.ModuleElement
getChildren, getComments, getData, getFile, getModule, getParent, getRegion, getUri, setModule, setParent, setRegion, setUri
-
Field Details
-
sourceParameter
-
domainBlock
-
targetBlock
-
templateBlock
-
guardBlock
-
overwriteBlock
-
mergeBlock
-
appendBlock
-
patchBlock
-
preBlock
-
postBlock
-
parametersBlock
-
formatterBlock
-
-
Constructor Details
-
GenerationRule
public GenerationRule()
-
-
Method Details
-
build
- Specified by:
build
in interfaceModuleElement
- Overrides:
build
in classExtensibleNamedRule
-
getAllElements
- Throws:
EolRuntimeException
-
execute
- Specified by:
execute
in interfaceIExecutableModuleElementParameter
- Throws:
EolRuntimeException
-
execute
- Specified by:
execute
in interfaceIExecutableModuleElement
- Throws:
EolRuntimeException
-
getOwningModelForType
Gets the model which the "transform" parameter type expression belongs to.- Parameters:
context
-- Returns:
- The model for the parameter.
- Throws:
EolRuntimeException
- Since:
- 1.6
-
toString
-
getSuperRulesAst
- Specified by:
getSuperRulesAst
in classExtensibleNamedRule
-
accept
-
getTransformSource
Gets the parameter bound to the "transform" part, ifhasTransformSource()
== true.- Returns:
- The part following "transform", or
null
if absent. - Since:
- 2.3
-
hasTransformSource
public boolean hasTransformSource()Used to determine whether this rule operates over a collection of model elements.- Returns:
true
if the rule has a "transform" part.- Since:
- 2.3
-
getDomainBlock
- Returns:
- Since:
- 2.3
-
getTargetBlock
- Returns:
- Since:
- 2.3
-
getTemplateBlock
- Returns:
- Since:
- 2.3
-
getGuardBlock
- Returns:
- Since:
- 2.3
-
getOverwriteBlock
- Returns:
- Since:
- 2.3
-
getMergeBlock
- Returns:
- Since:
- 2.3
-
getPreBlock
- Returns:
- Since:
- 2.3
-
getPostBlock
- Returns:
- Since:
- 2.3
-
getParametersBlock
- Returns:
- Since:
- 2.3
-
getFormatterBlock
- Returns:
- Since:
- 2.5
-