public class Node_RuleVariable extends Node_Variable
Note that this should not be used in a real Triple, in particular it should not end up in a Graph. It is only needed for the rule systems.
Node_Variable.VariableNameNode.NotLiteral| Modifier and Type | Field and Description |
|---|---|
static Node_RuleVariable |
WILD
A static wildcard - like Node.ANY but tests equal to other Node_RuleVariables
|
| Constructor and Description |
|---|
Node_RuleVariable(String label,
int index)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
Node_RuleVariable |
cloneNode()
Clone the rule variable to allow multiple rule instaces to be active at the same time.
|
Node |
deref()
Dereference a variable by following the reference chain.
|
boolean |
equals(Object o)
Nodes only equal other Nodes that have equal labels.
|
int |
getIndex()
Returns the variable's index in a binding vector.
|
Node |
getRawBoundValue()
Return the raw value to which this variable is bound (via LP binding) with
no dereferencing.
|
int |
hashCode() |
boolean |
isUnbound()
Test if the variable is unbound (in the brule sense).
|
static boolean |
sameNodeAs(Node n,
Node m)
Compare two nodes, taking into account variable indices.
|
boolean |
sameValueAs(Object o)
Test that two nodes are semantically equivalent.
|
void |
setIndex(int index)
Changes the variable's index.
|
void |
simpleBind(Node node)
Binds a value to the brule version of the variable.
|
String |
toString()
printable form
|
void |
unbind()
Set the variable to be unbound (in the brule sense)
|
getName, isVariable, variable, visitWithisConcretecreate, getBlankNodeId, getBlankNodeLabel, getIndexingValue, getLiteral, getLiteralDatatype, getLiteralDatatypeURI, getLiteralIsXML, getLiteralLanguage, getLiteralLexicalForm, getLiteralValue, getLocalName, getNameSpace, getURI, hasURI, isBlank, isLiteral, isURI, matches, toString, toString, toStringpublic static final Node_RuleVariable WILD
public Node_RuleVariable(String label, int index)
label - the text label for the variableindex - the calculated index of this variable in the rulepublic int getIndex()
public void setIndex(int index)
public void simpleBind(Node node)
node - a concrete Node value or another Node_RuleVariable
to alias topublic Node deref()
public Node getRawBoundValue()
public void unbind()
public boolean isUnbound()
public Node_RuleVariable cloneNode()
public String toString()
toString in class Node_Variablepublic boolean equals(Object o)
Nodeequals in class Node_Variablepublic boolean sameValueAs(Object o)
sameValueAs in class NodeLicenced under the Apache License, Version 2.0