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
FieldsModifier 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 Parameterprotected ExecutableBlock<String>protected ExecutableBlock<String>Fields inherited from class org.eclipse.epsilon.erl.dom.ExtensibleNamedRule
allSuperRules, isAbstract, isGreedy, isLazy, isParallel, ofKindCache, ofTypeCache, superRules, superRulesIdentifiersFields inherited from class org.eclipse.epsilon.erl.dom.NamedRule
nameExpressionFields inherited from class org.eclipse.epsilon.eol.dom.AnnotatableModuleElement
annotationBlock -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaccept(IEgxVisitor visitor) voidexecute(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.booleanUsed 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, isParallelMethods inherited from class org.eclipse.epsilon.erl.dom.NamedRule
equals, getName, getNameAst, getNameExpression, hashCodeMethods inherited from class org.eclipse.epsilon.eol.dom.AnnotatableModuleElement
accept, getAnnotation, getAnnotationBlock, getAnnotations, getAnnotationsValues, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, hasAnnotation, setAnnotationBlockMethods inherited from class org.eclipse.epsilon.common.module.AbstractModuleElement
getChildren, getComments, getData, getDebugInfo, getFile, getModule, getParent, getRegion, getUri, setModule, setParent, setRegion, setUriMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods 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:
buildin interfaceModuleElement- Overrides:
buildin classExtensibleNamedRule
-
getAllElements
- Throws:
EolRuntimeException
-
execute
- Specified by:
executein interfaceIExecutableModuleElementParameter- Throws:
EolRuntimeException
-
execute
- Specified by:
executein 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:
getSuperRulesAstin classExtensibleNamedRule
-
accept
-
getTransformSource
Gets the parameter bound to the "transform" part, ifhasTransformSource()== true.- Returns:
- The part following "transform", or
nullif absent. - Since:
- 2.3
-
hasTransformSource
public boolean hasTransformSource()Used to determine whether this rule operates over a collection of model elements.- Returns:
trueif 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
-