public class TransformationRule extends ExtensibleNamedRule
Modifier and Type | Field and Description |
---|---|
protected ExecutableBlock<Void> |
body |
protected IEtlContext |
context |
protected ExecutableBlock<Boolean> |
guard |
protected Boolean |
isPrimary |
protected Collection<Object> |
rejected |
protected Parameter |
sourceParameter |
protected List<Parameter> |
targetParameters |
protected Set<Object> |
transformedElements |
allSuperRules, isAbstract, isGreedy, isLazy, ofKindCache, ofTypeCache, superRules, superRulesIdentifiers
nameExpression
annotationBlock
Constructor and Description |
---|
TransformationRule() |
calculateSuperRules, calculateSuperRules, getAllInstances, getAllOfKind, getAllOfType, getAllSuperRules, getRuleByName, getSuperRules, isAbstract, isGreedy
equals, getName, getNameAst, getNameExpression, hashCode, setNameExpression
getAnnotation, getAnnotationBlock, getAnnotations, getAnnotationsValues, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, hasAnnotation, setAnnotationBlock
getChildren, getComments, getDebugInfo, getFile, getModule, getParent, getRegion, getUri, setModule, setParent, setRegion, setUri
protected Parameter sourceParameter
protected ExecutableBlock<Boolean> guard
protected ExecutableBlock<Void> body
protected IEtlContext context
protected Boolean isPrimary
protected Collection<Object> rejected
public AST getSuperRulesAst(AST cst)
getSuperRulesAst
in class ExtensibleNamedRule
public Parameter getSourceParameter()
public void setSourceParameter(Parameter sourceParameter)
public ExecutableBlock<Void> getBody()
public void setBody(ExecutableBlock<Void> body)
public ExecutableBlock<Boolean> getGuard()
public void setGuard(ExecutableBlock<Boolean> guard)
public void build(AST cst, IModule module)
build
in interface ModuleElement
build
in class ExtensibleNamedRule
public boolean isLazy(IEolContext context) throws EolRuntimeException
isLazy
in class ExtensibleNamedRule
EolRuntimeException
public boolean hasTransformed(Object source)
public boolean appliesTo(Object source, IEtlContext context, boolean asSuperRule) throws EolRuntimeException
EolRuntimeException
public boolean appliesTo(Object source, IEtlContext context, boolean asSuperRule, boolean checkTypes) throws EolRuntimeException
EolRuntimeException
public Collection<?> getAllInstances(IEtlContext context) throws EolRuntimeException
context
- EolRuntimeException
public void transformAll(IEtlContext context, Collection<Object> excluded, boolean includeLazy) throws EolRuntimeException
context
- excluded
- includeLazy
- Whether to transform lazy rules.EolRuntimeException
public Collection<?> transform(Object source, Collection<Object> targets, IEtlContext context) throws EolRuntimeException
EolRuntimeException
public Collection<?> transform(Object source, IEtlContext context) throws EolRuntimeException
EolRuntimeException
protected void executeSuperRulesAndBody(Object source, Collection<Object> targets_, IEtlContext context) throws EolRuntimeException
EolRuntimeException
public boolean isPrimary(IEtlContext context) throws EolRuntimeException
EolRuntimeException
public boolean canTransformExcluded(IEtlContext context) throws EolRuntimeException
EolRuntimeException
public boolean shouldBeTransformed(Object instance, Collection<Object> excluded, IEtlContext context, boolean overrideLazy) throws EolRuntimeException
EolRuntimeException
public void dispose()
Copyright © 2020. All rights reserved.