|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.kahina.core.breakpoint.TreeNodePattern
public class TreeNodePattern
TreeNodePatterns are a means of defining which nodes are accepted for use within TreeAutomatonRules as part of the Kahina breakpoint mechanism. Some basic functionality is predefined, allowing the user to exploit Kahina's predefined tree node properties such as For more complex breakpoint patterns based on associated step data, it is possible to use one of the specialized TreeNodePattern classes (such as SourceCodePattern) or to directly inherit from this class and overwrite or overload the decision methods. It is not recommended to use this for child pattern matching, because this breaks the tree automaton logic. For such patterns, use the TreeAutomaton mechanism of node annotations.
| Field Summary | |
|---|---|
static int |
CAPTION
|
static int |
CONJUNCTION
|
static int |
CONTAINS
|
static int |
DISJUNCTION
|
static int |
EDGE_LABEL
|
static int |
ENDS_WITH
|
static int |
EQUALITY
|
static int |
GREATER
|
static int |
GREATER_OR_EQUAL
|
static int |
ID
|
static int |
IDENTITY
|
static int |
IMPLICATION
|
static int |
LESS
|
static int |
LESS_OR_EQUAL
|
static int |
MATCHING
|
static int |
NEGATION
|
static int |
STARTS_WITH
|
static int |
STATUS
|
| Constructor Summary | |
|---|---|
TreeNodePattern()
|
|
TreeNodePattern(int type,
int rel,
int value)
|
|
TreeNodePattern(int type,
int rel,
String value)
|
|
TreeNodePattern(int type,
TreeNodePattern leftArg)
|
|
TreeNodePattern(int type,
TreeNodePattern leftArg,
TreeNodePattern rightArg)
|
|
| Method Summary | |
|---|---|
String |
exportXML(boolean asFile)
|
TreeNodePattern |
getLeftArgument()
|
int |
getRel()
|
String |
getRelAsString()
|
String |
getRelAsXMLString()
|
TreeNodePattern |
getRightArgument()
|
int |
getType()
|
String |
getTypeAsString()
|
String |
getTypeAsXMLString()
|
String |
getTypeString()
defines a very short symbolic representation of the type for an atomic pattern is the empty string for complex nodes or non-standard types inheriting classes should reimplement this if they add more types, relying on this version for the standard types |
String |
getValueAsString()
|
String |
getValueString()
defines a representation of the relation and the value is the empty string for complex nodes or non-standard relations inheriting classes should reimplement this if they add more relations or value types, relying on this version for the standard types |
static TreeNodePattern |
importXML(Element treeNodePatternNode)
|
boolean |
matches(KahinaTree m,
int nodeID)
|
void |
parseValue(String value)
|
void |
setLeftArgument(TreeNodePattern left)
|
void |
setRel(int rel)
|
void |
setRelation(String relString)
|
void |
setRightArgument(TreeNodePattern right)
|
void |
setType(int type)
|
void |
setType(String typeString)
|
void |
setXMLRelation(String relString)
|
void |
setXMLType(String typeString)
|
void |
switchArguments()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final int CAPTION
public static final int EDGE_LABEL
public static final int STATUS
public static final int ID
public static final int NEGATION
public static final int CONJUNCTION
public static final int DISJUNCTION
public static final int IMPLICATION
public static final int IDENTITY
public static final int LESS
public static final int GREATER
public static final int LESS_OR_EQUAL
public static final int GREATER_OR_EQUAL
public static final int EQUALITY
public static final int MATCHING
public static final int STARTS_WITH
public static final int CONTAINS
public static final int ENDS_WITH
| Constructor Detail |
|---|
public TreeNodePattern()
public TreeNodePattern(int type,
int rel,
int value)
public TreeNodePattern(int type,
int rel,
String value)
public TreeNodePattern(int type,
TreeNodePattern leftArg)
public TreeNodePattern(int type,
TreeNodePattern leftArg,
TreeNodePattern rightArg)
| Method Detail |
|---|
public void parseValue(String value)
throws PatternFormatException
PatternFormatExceptionpublic int getType()
public void setType(int type)
public int getRel()
public void setRel(int rel)
public void setLeftArgument(TreeNodePattern left)
public void setRightArgument(TreeNodePattern right)
public void switchArguments()
public TreeNodePattern getLeftArgument()
public TreeNodePattern getRightArgument()
public boolean matches(KahinaTree m,
int nodeID)
public String toString()
toString in class Objectpublic String getTypeString()
public String getValueString()
public String getTypeAsString()
public String getRelAsString()
public String getValueAsString()
public void setType(String typeString)
public void setXMLType(String typeString)
public void setRelation(String relString)
public void setXMLRelation(String relString)
public String getTypeAsXMLString()
public String getRelAsXMLString()
public String exportXML(boolean asFile)
public static TreeNodePattern importXML(Element treeNodePatternNode)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||