org.w3c.rdf.implementation.model
Class StatementImpl

java.lang.Object
  |
  +--org.w3c.rdf.implementation.model.StatementImpl
All Implemented Interfaces:
RDFNode, Resource, Statement

public final class StatementImpl
extends java.lang.Object
implements Statement


Constructor Summary
StatementImpl(Resource subj, Resource pred, RDFNode obj)
          The parameters to constructor are instances of classes and not just strings
 
Method Summary
 boolean equals(java.lang.Object that)
           
 java.lang.String getLabel()
          The formal string label of the node.
 java.lang.String getLocalName()
          Returns the local name of the resource.
 java.lang.String getNamespace()
          Returns the namespace of the resource.
 java.lang.String getURI()
          Returns the URI of the resource.
 int hashCode()
           
static void main(java.lang.String[] args)
           
 java.lang.String node2string(RDFNode n)
           
 RDFNode object()
           
 Resource predicate()
           
 Resource subject()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StatementImpl

public StatementImpl(Resource subj,
                     Resource pred,
                     RDFNode obj)
The parameters to constructor are instances of classes and not just strings
Method Detail

predicate

public Resource predicate()
Specified by:
predicate in interface Statement
Following copied from interface: org.w3c.rdf.model.Statement
Returns:
predicate of the triple

subject

public Resource subject()
Specified by:
subject in interface Statement
Following copied from interface: org.w3c.rdf.model.Statement
Returns:
subject of the triple

object

public RDFNode object()
Specified by:
object in interface Statement
Following copied from interface: org.w3c.rdf.model.Statement
Returns:
object of the triple

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object
Returns:
four most significant bytes of the digest

getURI

public java.lang.String getURI()
                        throws ModelException
Description copied from interface: Resource
Returns the URI of the resource. Triples and models must implement this method in a standard way.
Specified by:
getURI in interface Resource
Following copied from interface: org.w3c.rdf.model.Resource
Returns:
the URI of the resource
See Also:
Statement, Model

getLabel

public java.lang.String getLabel()
                          throws ModelException
Description copied from interface: RDFNode
The formal string label of the node. URI in case of a resource, string in case of a literal.
Specified by:
getLabel in interface RDFNode

getNamespace

public java.lang.String getNamespace()
Description copied from interface: Resource
Returns the namespace of the resource. May return null.
Specified by:
getNamespace in interface Resource
Following copied from interface: org.w3c.rdf.model.Resource
Returns:
the namespace of the resource
See Also:
Statement, Model

getLocalName

public java.lang.String getLocalName()
                              throws ModelException
Description copied from interface: Resource
Returns the local name of the resource. May not return null.
Specified by:
getLocalName in interface Resource
Following copied from interface: org.w3c.rdf.model.Resource
Returns:
the local name of the resource
See Also:
Statement, Model

node2string

public java.lang.String node2string(RDFNode n)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object that)
Overrides:
equals in class java.lang.Object

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception