org.jrdf.graph.local.mem
Class URIReferenceResourceImpl

java.lang.Object
  extended by org.jrdf.graph.local.mem.AbstractResource
      extended by org.jrdf.graph.local.mem.URIReferenceResourceImpl
All Implemented Interfaces:
Serializable, BlankNode, LocalizedNode, Node, ObjectNode, PredicateNode, Resource, SubjectNode, TypedNodeVisitable, URIReference

public final class URIReferenceResourceImpl
extends AbstractResource

See Also:
Serialized Form

Method Summary
 void accept(TypedNodeVisitor visitor)
          Accept a call from a TypedNodeVisitor.
 boolean equals(Object obj)
          While the internal structure of a BlankNode is not defined equality between two nodes should be able to be determined.
 Node getUnderlyingNode()
          Returns the node that the resource represents - either a BlankNode or a URIReference.
 URI getURI()
          The URI identifiying this resource.
 int hashCode()
          Returns a hash-code value for this BlankNode.
 boolean isURIReference()
          Returns true if this is a URIReference, otherwise it's a BlankNode.
 String toString()
           
 
Methods inherited from class org.jrdf.graph.local.mem.AbstractResource
addValue, getId, getObjects, getSubjects, removeSubject, removeValue, removeValues, setValue
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

isURIReference

public boolean isURIReference()
Description copied from interface: Resource
Returns true if this is a URIReference, otherwise it's a BlankNode.

Returns:
true if this is a URIReference, otherwise it's a BlankNode.

getUnderlyingNode

public Node getUnderlyingNode()
Description copied from interface: Resource
Returns the node that the resource represents - either a BlankNode or a URIReference.

Returns:
the BlankNode or URIReference.

getURI

public URI getURI()
Description copied from interface: URIReference
The URI identifiying this resource.

Returns:
the URI identifying this resource.

hashCode

public int hashCode()
Description copied from interface: BlankNode
Returns a hash-code value for this BlankNode. While the implementation is not defined, if there is a blank node identifier then it should be the hash code generated from this. Hash code generation should follow the normal contract.

Specified by:
hashCode in interface BlankNode
Specified by:
hashCode in interface URIReference
Overrides:
hashCode in class Object
Returns:
a hash-code value for this blank node.

equals

public boolean equals(Object obj)
Description copied from interface: BlankNode
While the internal structure of a BlankNode is not defined equality between two nodes should be able to be determined. In some representations this equality would be defined by a blank node identifier.

Specified by:
equals in interface BlankNode
Specified by:
equals in interface URIReference
Overrides:
equals in class Object
Parameters:
obj - the reference object with which to compare.
Returns:
true if this object is the same as the obj argument; false otherwise.

accept

public void accept(TypedNodeVisitor visitor)
Description copied from interface: TypedNodeVisitable
Accept a call from a TypedNodeVisitor.

Parameters:
visitor - the object doing the visiting.

toString

public String toString()
Overrides:
toString in class Object