public abstract class BasePatternMatch extends java.lang.Object implements IPatternMatch
Constructor and Description |
---|
BasePatternMatch() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
get(int position)
Returns the value of the parameter at the given position, or null if position is invalid.
|
boolean |
isCompatibleWith(IPatternMatch other)
Checks that this match is compatible with the given other match.
|
protected static <T> java.util.List<T> |
makeImmutableList(T... elements) |
java.util.List<java.lang.String> |
parameterNames()
Returns the list of symbolic parameter names.
|
java.lang.String |
patternName()
Identifies the name of the pattern for which this is a match.
|
static java.lang.String |
prettyPrintFeature(java.lang.Object o,
java.lang.String featureName) |
static java.lang.String |
prettyPrintValue(java.lang.Object o) |
boolean |
set(int position,
java.lang.Object newValue)
Sets the parameter at the given position to the given value.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
get, isMutable, prettyPrint, set, specification, toArray, toImmutable
@SafeVarargs protected static <T> java.util.List<T> makeImmutableList(T... elements)
public static java.lang.String prettyPrintValue(java.lang.Object o)
public static java.lang.String prettyPrintFeature(java.lang.Object o, java.lang.String featureName)
public java.lang.Object get(int position)
IPatternMatch
get
in interface IPatternMatch
public boolean set(int position, java.lang.Object newValue)
IPatternMatch
Works only if match is mutable. See IPatternMatch.isMutable()
.
set
in interface IPatternMatch
public java.lang.String toString()
toString
in class java.lang.Object
public boolean isCompatibleWith(IPatternMatch other)
IPatternMatch
isCompatibleWith
in interface IPatternMatch
public java.lang.String patternName()
IPatternMatch
patternName
in interface IPatternMatch
public java.util.List<java.lang.String> parameterNames()
IPatternMatch
parameterNames
in interface IPatternMatch