public class MatchRule extends ExtensibleNamedRule
| Modifier and Type | Field and Description |
|---|---|
protected org.eclipse.epsilon.eol.dom.ExecutableBlock<Boolean> |
compareBlock |
protected org.eclipse.epsilon.eol.dom.ExecutableBlock<Void> |
doBlock |
protected org.eclipse.epsilon.eol.dom.ExecutableBlock<Boolean> |
guardBlock |
protected org.eclipse.epsilon.eol.dom.Parameter |
leftParameter |
protected org.eclipse.epsilon.eol.dom.Parameter |
rightParameter |
allSuperRules, isAbstract, isGreedy, isLazy, ofKindCache, ofTypeCache, superRules, superRulesIdentifiersnameExpression| Constructor and Description |
|---|
MatchRule() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
appliesTo(Object left,
Object right,
IEclContext context,
boolean ofTypeOnly) |
void |
build(org.eclipse.epsilon.common.parse.AST cst,
org.eclipse.epsilon.common.module.IModule module) |
Collection<?> |
getLeftInstances(IEclContext context,
boolean ofTypeOnly) |
Collection<?> |
getRightInstances(IEclContext context,
boolean ofTypeOnly) |
org.eclipse.epsilon.common.parse.AST |
getSuperRulesAst(org.eclipse.epsilon.common.parse.AST cst) |
Match |
match(Object left,
Object right,
IEclContext context,
org.eclipse.epsilon.eol.types.EolMap<?,?> matchInfo,
boolean forcedMatch)
Matches left against right
|
Match |
matchPair(IEclContext context,
boolean ofTypeOnly,
Object leftInstance,
Object rightInstance) |
String |
toString() |
calculateSuperRules, calculateSuperRules, getAllInstances, getAllOfKind, getAllOfType, getAllSuperRules, getRuleByName, getSuperRules, isAbstract, isGreedy, isLazyequals, getName, getNameAst, getNameExpression, hashCode, setNameExpressiongetAnnotation, getAnnotationBlock, getAnnotations, getAnnotationsValues, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, getBooleanAnnotationValue, hasAnnotation, setAnnotationBlockprotected org.eclipse.epsilon.eol.dom.ExecutableBlock<Boolean> compareBlock
protected org.eclipse.epsilon.eol.dom.ExecutableBlock<Boolean> guardBlock
protected org.eclipse.epsilon.eol.dom.ExecutableBlock<Void> doBlock
protected org.eclipse.epsilon.eol.dom.Parameter leftParameter
protected org.eclipse.epsilon.eol.dom.Parameter rightParameter
public org.eclipse.epsilon.common.parse.AST getSuperRulesAst(org.eclipse.epsilon.common.parse.AST cst)
getSuperRulesAst in class ExtensibleNamedRulepublic void build(org.eclipse.epsilon.common.parse.AST cst,
org.eclipse.epsilon.common.module.IModule module)
build in interface org.eclipse.epsilon.common.module.ModuleElementbuild in class ExtensibleNamedRulepublic boolean appliesTo(Object left, Object right, IEclContext context, boolean ofTypeOnly) throws org.eclipse.epsilon.eol.exceptions.EolRuntimeException
org.eclipse.epsilon.eol.exceptions.EolRuntimeExceptionpublic Collection<?> getLeftInstances(IEclContext context, boolean ofTypeOnly) throws org.eclipse.epsilon.eol.exceptions.EolRuntimeException
org.eclipse.epsilon.eol.exceptions.EolRuntimeExceptionpublic Collection<?> getRightInstances(IEclContext context, boolean ofTypeOnly) throws org.eclipse.epsilon.eol.exceptions.EolRuntimeException
org.eclipse.epsilon.eol.exceptions.EolRuntimeExceptionpublic Match matchPair(IEclContext context, boolean ofTypeOnly, Object leftInstance, Object rightInstance) throws org.eclipse.epsilon.eol.exceptions.EolRuntimeException
org.eclipse.epsilon.eol.exceptions.EolRuntimeExceptionpublic Match match(Object left, Object right, IEclContext context, org.eclipse.epsilon.eol.types.EolMap<?,?> matchInfo, boolean forcedMatch) throws org.eclipse.epsilon.eol.exceptions.EolRuntimeException
left - The left objectright - The right objectcontext - The context in which the ECL program is runningasSuperRule - Shows if the rule is executed as a super-rule of another ruleforcedMatch - Whether to add the match to the trace (?)org.eclipse.epsilon.eol.exceptions.EolRuntimeExceptionCopyright © 2020. All rights reserved.