com.hp.hpl.jena.graph
Class Node_Variable

java.lang.Object
  extended by com.hp.hpl.jena.graph.Node
      extended by com.hp.hpl.jena.graph.Node_Fluid
          extended by com.hp.hpl.jena.graph.Node_Variable
Direct Known Subclasses:
Node_RuleVariable

public class Node_Variable
extends Node_Fluid

"variable" nodes; these are outside the RDF2003 specification, but are used internally for "placeholder" nodes where blank nodes would be wrong, most specifically in Query.

Author:
kers

Nested Class Summary
static class Node_Variable.VariableName
           
 
Nested classes/interfaces inherited from class com.hp.hpl.jena.graph.Node
Node.NotLiteral
 
Field Summary
 
Fields inherited from class com.hp.hpl.jena.graph.Node
ANY, NULL
 
Constructor Summary
Node_Variable(String name)
          Initialise this Node_Variable from a string name, which becomes wrapped in a VariableName.
 
Method Summary
 boolean equals(Object other)
          Nodes only equal other Nodes that have equal labels.
 String getName()
          get a variable nodes name, otherwise die horribly
 boolean isVariable()
          Answer true iff this node is a variable node - subclasses override
 String toString()
          Answer a human-readable representation of this Node.
static Object variable(String name)
           
 Object visitWith(NodeVisitor v)
          Visit a Node and dispatch on it to the appropriate method from the NodeVisitor v.
 
Methods inherited from class com.hp.hpl.jena.graph.Node_Fluid
isConcrete
 
Methods inherited from class com.hp.hpl.jena.graph.Node
cache, create, createAnon, createAnon, createLiteral, createLiteral, createLiteral, createLiteral, createLiteral, createUncachedLiteral, createUncachedLiteral, createURI, createVariable, getBlankNodeId, getBlankNodeLabel, getIndexingValue, getLiteral, getLiteralDatatype, getLiteralDatatypeURI, getLiteralIsXML, getLiteralLanguage, getLiteralLexicalForm, getLiteralValue, getLocalName, getNameSpace, getType, getURI, hashCode, hasURI, isBlank, isLiteral, isURI, matches, sameValueAs, toString, toString, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Node_Variable

public Node_Variable(String name)
Initialise this Node_Variable from a string name, which becomes wrapped in a VariableName.

Method Detail

getName

public String getName()
Description copied from class: Node
get a variable nodes name, otherwise die horribly

Overrides:
getName in class Node

visitWith

public Object visitWith(NodeVisitor v)
Description copied from class: Node
Visit a Node and dispatch on it to the appropriate method from the NodeVisitor v.

Specified by:
visitWith in class Node
Parameters:
v - the visitor to apply to the node
Returns:
the value returned by the applied method

isVariable

public boolean isVariable()
Description copied from class: Node
Answer true iff this node is a variable node - subclasses override

Overrides:
isVariable in class Node

toString

public String toString()
Description copied from class: Node
Answer a human-readable representation of this Node. It will not compress URIs, nor quote literals (because at the moment too many places use toString() for something machine-oriented).

Overrides:
toString in class Node

equals

public boolean equals(Object other)
Description copied from class: Node
Nodes only equal other Nodes that have equal labels.

Specified by:
equals in class Node

variable

public static Object variable(String name)


Licenced under the Apache License, Version 2.0