org.openanzo.common.ontology
Class DatasetImpl

java.lang.Object
  extended by org.openanzo.jastor.GraphThingImpl
      extended by org.openanzo.common.ontology.DatasetImpl
All Implemented Interfaces:
Dataset, CoreThing, GraphThing

public class DatasetImpl
extends GraphThingImpl
implements Dataset

Implementation of Dataset Use the org.openanzo.common.ontology.AnzoFactory to create instances of this class.

(URI: http://openanzo.org/types/Dataset)



Field Summary
 
Fields inherited from interface org.openanzo.common.ontology.Dataset
TYPE
 
Method Summary
 NamedGraph addDefaultGraph()
          Adds an anonymous value for the 'defaultGraph' property
 void addDefaultGraph(NamedGraph defaultGraph)
          Adds a value for the 'defaultGraph' property
 NamedGraph addDefaultGraph(org.openrdf.model.Resource resource)
          Adds a value for the 'defaultGraph' property.
 NamedGraph addNamedGraph()
          Adds an anonymous value for the 'namedGraph' property
 void addNamedGraph(NamedGraph namedGraph)
          Adds a value for the 'namedGraph' property
 NamedGraph addNamedGraph(org.openrdf.model.Resource resource)
          Adds a value for the 'namedGraph' property.
 info.aduna.collections.iterators.CloseableIterator<NamedGraph> getDefaultGraph()
          Get an Iterator the 'defaultGraph' property values.
 info.aduna.collections.iterators.CloseableIterator<NamedGraph> getNamedGraph()
          Get an Iterator the 'namedGraph' property values.
 java.util.Collection<org.openrdf.model.Statement> listStatements()
          Get set of statements that makeup this THINGS's properties and types
 void registerListener(ThingListener listener)
          Register a ThingListener for this THING
 void removeDefaultGraph(NamedGraph defaultGraph)
          Removes a value for the 'defaultGraph' property.
 void removeDefaultGraph(org.openrdf.model.Resource defaultGraph)
          Remove a 'defaultGraph' property value.
 void removeNamedGraph(NamedGraph namedGraph)
          Removes a value for the 'namedGraph' property.
 void removeNamedGraph(org.openrdf.model.Resource namedGraph)
          Remove a 'namedGraph' property value.
 void unregisterListener(ThingListener listener)
          Unregister a ThingListener for this THING
 
Methods inherited from class org.openanzo.jastor.GraphThingImpl
clearCache, equals, getLiteral, getLiteralValue, getProperties, getPropertyValue, getPropertyValue, graph, isRDFType, removeStatements, resource, setPropertyValue, setPropertyValue, toString, uri
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.openanzo.jastor.GraphThing
getProperties, getPropertyValue, getPropertyValue, graph, setPropertyValue, setPropertyValue
 
Methods inherited from interface org.openanzo.jastor.CoreThing
clearCache, isRDFType, removeStatements, resource, uri
 

Method Detail

listStatements

public java.util.Collection<org.openrdf.model.Statement> listStatements()
Description copied from interface: CoreThing
Get set of statements that makeup this THINGS's properties and types

Specified by:
listStatements in interface CoreThing
Overrides:
listStatements in class GraphThingImpl
Returns:
set of statements that makeup this THINGS's properties and types

getDefaultGraph

public info.aduna.collections.iterators.CloseableIterator<NamedGraph> getDefaultGraph()
                                                                               throws JastorException
Description copied from interface: Dataset
Get an Iterator the 'defaultGraph' property values. This Iteartor may be used to remove all such values.

Specified by:
getDefaultGraph in interface Dataset
Returns:
Iterator of NamedGraph
Throws:
JastorException
See Also:
Dataset.defaultGraphProperty

addDefaultGraph

public void addDefaultGraph(NamedGraph defaultGraph)
                     throws JastorException
Description copied from interface: Dataset
Adds a value for the 'defaultGraph' property

Specified by:
addDefaultGraph in interface Dataset
Parameters:
defaultGraph - The NamedGraph to add
Throws:
JastorException
See Also:
Dataset.defaultGraphProperty

addDefaultGraph

public NamedGraph addDefaultGraph()
                           throws JastorException
Description copied from interface: Dataset
Adds an anonymous value for the 'defaultGraph' property

Specified by:
addDefaultGraph in interface Dataset
Returns:
The anoymous NamedGraph created
Throws:
JastorException
See Also:
Dataset.defaultGraphProperty

addDefaultGraph

public NamedGraph addDefaultGraph(org.openrdf.model.Resource resource)
                           throws JastorException
Description copied from interface: Dataset
Adds a value for the 'defaultGraph' property. This method is equivalent constructing a new instance of NamedGraph with the factory and calling addDefaultGraph(org.openanzo.common.ontology.NamedGraph defaultGraph) The resource argument have rdf:type http://openanzo.org/types/NamedGraph. That is, this method should not be used as a shortcut for creating new objects in the model.

Specified by:
addDefaultGraph in interface Dataset
Parameters:
resource - The Resource to add
Returns:
The org.openanzo.common.ontology.NamedGraph created
Throws:
JastorException
See Also:
Dataset.defaultGraphProperty

removeDefaultGraph

public void removeDefaultGraph(NamedGraph defaultGraph)
                        throws JastorException
Description copied from interface: Dataset
Removes a value for the 'defaultGraph' property. This method should not be invoked while iterator through values. In that case, the remove() method of the Iterator itself should be used.

Specified by:
removeDefaultGraph in interface Dataset
Parameters:
defaultGraph - The NamedGraph to remove
Throws:
JastorException
See Also:
Dataset.defaultGraphProperty

removeDefaultGraph

public void removeDefaultGraph(org.openrdf.model.Resource defaultGraph)
                        throws JastorException
Description copied from interface: Dataset
Remove a 'defaultGraph' property value. This method should not be invoked while iterator through values. In that case, the remove() method of the Iterator itself should be used.

Specified by:
removeDefaultGraph in interface Dataset
Parameters:
defaultGraph - NamedGraph, the value to remove
Throws:
JastorException
See Also:
Dataset.defaultGraphProperty

getNamedGraph

public info.aduna.collections.iterators.CloseableIterator<NamedGraph> getNamedGraph()
                                                                             throws JastorException
Description copied from interface: Dataset
Get an Iterator the 'namedGraph' property values. This Iteartor may be used to remove all such values.

Specified by:
getNamedGraph in interface Dataset
Returns:
Iterator of NamedGraph
Throws:
JastorException
See Also:
Dataset.namedGraphProperty

addNamedGraph

public void addNamedGraph(NamedGraph namedGraph)
                   throws JastorException
Description copied from interface: Dataset
Adds a value for the 'namedGraph' property

Specified by:
addNamedGraph in interface Dataset
Parameters:
namedGraph - The NamedGraph to add
Throws:
JastorException
See Also:
Dataset.namedGraphProperty

addNamedGraph

public NamedGraph addNamedGraph()
                         throws JastorException
Description copied from interface: Dataset
Adds an anonymous value for the 'namedGraph' property

Specified by:
addNamedGraph in interface Dataset
Returns:
The anoymous NamedGraph created
Throws:
JastorException
See Also:
Dataset.namedGraphProperty

addNamedGraph

public NamedGraph addNamedGraph(org.openrdf.model.Resource resource)
                         throws JastorException
Description copied from interface: Dataset
Adds a value for the 'namedGraph' property. This method is equivalent constructing a new instance of NamedGraph with the factory and calling addNamedGraph(org.openanzo.common.ontology.NamedGraph namedGraph) The resource argument have rdf:type http://openanzo.org/types/NamedGraph. That is, this method should not be used as a shortcut for creating new objects in the model.

Specified by:
addNamedGraph in interface Dataset
Parameters:
resource - The Resource to add
Returns:
The org.openanzo.common.ontology.NamedGraph created
Throws:
JastorException
See Also:
Dataset.namedGraphProperty

removeNamedGraph

public void removeNamedGraph(NamedGraph namedGraph)
                      throws JastorException
Description copied from interface: Dataset
Removes a value for the 'namedGraph' property. This method should not be invoked while iterator through values. In that case, the remove() method of the Iterator itself should be used.

Specified by:
removeNamedGraph in interface Dataset
Parameters:
namedGraph - The NamedGraph to remove
Throws:
JastorException
See Also:
Dataset.namedGraphProperty

removeNamedGraph

public void removeNamedGraph(org.openrdf.model.Resource namedGraph)
                      throws JastorException
Description copied from interface: Dataset
Remove a 'namedGraph' property value. This method should not be invoked while iterator through values. In that case, the remove() method of the Iterator itself should be used.

Specified by:
removeNamedGraph in interface Dataset
Parameters:
namedGraph - NamedGraph, the value to remove
Throws:
JastorException
See Also:
Dataset.namedGraphProperty

registerListener

public void registerListener(ThingListener listener)
Description copied from interface: CoreThing
Register a ThingListener for this THING

Specified by:
registerListener in interface CoreThing
Overrides:
registerListener in class GraphThingImpl
Parameters:
listener - ThingListener

unregisterListener

public void unregisterListener(ThingListener listener)
Description copied from interface: CoreThing
Unregister a ThingListener for this THING

Specified by:
unregisterListener in interface CoreThing
Overrides:
unregisterListener in class GraphThingImpl
Parameters:
listener - ThingListener


Copyright © 2007 Cambridge Semantics Inc.. All Rights Reserved.