public class TermLabelCondition extends VariableConditionAdapter
Modifier and Type | Field and Description |
---|---|
private TermLabelSV |
l |
private Name |
ln |
private boolean |
negated |
Constructor and Description |
---|
TermLabelCondition(TermLabelSV l,
java.lang.String t,
boolean negated) |
Modifier and Type | Method and Description |
---|---|
boolean |
check(SchemaVariable var,
SVSubstitute instCandidate,
SVInstantiations instMap,
Services services)
checks if the condition for a correct instantiation is fulfilled
|
(package private) static boolean |
hasLabel(ImmutableArray<?> labels,
Name name)
Checks if an array of label contains the label specified in this condition
|
java.lang.String |
toString() |
check
private final TermLabelSV l
private final Name ln
private final boolean negated
public TermLabelCondition(TermLabelSV l, java.lang.String t, boolean negated)
public boolean check(SchemaVariable var, SVSubstitute instCandidate, SVInstantiations instMap, Services services)
VariableConditionAdapter
check
in class VariableConditionAdapter
var
- the template Variable to be instantiatedinstMap
- the MatchCondition with the current matching state and in particular
the SVInstantiations that are already known to be neededservices
- the program information objectstatic boolean hasLabel(ImmutableArray<?> labels, Name name)
labels
- array of labels in the term to be matchedname
- name of the label specified in this conditionpublic java.lang.String toString()
toString
in class java.lang.Object