| com.hp.hpl.jena.graph.Graph
All known Subclasses: com.hp.hpl.jena.mem.GraphMem, com.hp.hpl.jena.graph.compose.Intersection, com.hp.hpl.jena.db.GraphRDB, com.hp.hpl.jena.db.impl.DBReifierGraph, com.hp.hpl.jena.graph.compose.Union, com.hp.hpl.jena.graph.compose.Difference, com.hp.hpl.jena.graph.compose.Delta, com.hp.hpl.jena.mem.MixedGraphMem,
Graph | public interface Graph extends GraphAdd(Code) | | The interface to be satisfied by implementations maintaining collections
of RDF triples. The core interface is small (add, delete, find, contains) and
is augmented by additional classes to handle more complicated matters
such as reification, query handling, bulk update, event management,
and transaction handling.
For add(Triple) see GraphAdd.
author: Jeremy Carroll, Chris Dollin |
Field Summary | |
final public static Graph | emptyGraph An immutable empty graph. |
emptyGraph | final public static Graph emptyGraph(Code) | | An immutable empty graph.
|
close | void close()(Code) | | Free all resources, any further use of this Graph is an error.
|
contains | boolean contains(Node s, Node p, Node o)(Code) | | Answer true iff the graph contains a triple matching (s, p, o).
s/p/o may be concrete or fluid. Equivalent to find(s,p,o).hasNext,
but an implementation is expected to optimise this in easy cases.
|
contains | boolean contains(Triple t)(Code) | | Answer true iff the graph contains a triple that t matches; t may be
fluid.
|
dependsOn | boolean dependsOn(Graph other)(Code) | | true if this graph's content depends on the other graph. May be
pessimistic (ie return true if it's not sure). Typically true when a
graph is a composition of other graphs, eg union.
Parameters: other - the graph this graph may depend on false if this does not depend on other |
find | ExtendedIterator find(TripleMatch m)(Code) | | Returns an iterator over all the Triples that match the triple pattern.
Parameters: m - a Triple[Match] encoding the pattern to look for an iterator of all triples in this graph that match m |
getPrefixMapping | PrefixMapping getPrefixMapping()(Code) | | returns this Graph's prefix mapping. Each call on a given Graph gets the
same PrefixMapping object, which is the one used by the Graph.
|
getReifier | Reifier getReifier()(Code) | | returns this Graph's reifier. Each call on a given Graph gets the same
Reifier object.
|
getStatisticsHandler | GraphStatisticsHandler getStatisticsHandler()(Code) | | Answer this Graph's statistics handler, or null if there isn't one. Every
call to this method on a particular graph delivers the same (==) answer.
|
isClosed | boolean isClosed()(Code) | | Answer true iff .close() has been called onn this Graph.
|
isEmpty | boolean isEmpty()(Code) | | Answer true iff this graph is empty. "Empty" means "has as few triples as it
can manage", because an inference graph may have irremovable axioms
and their consequences.
|
size | int size()(Code) | | For a concrete graph this returns the number of triples in the graph. For graphs which
might infer additional triples it results an estimated lower bound of the number of triples.
For example, an inference graph might return the number of triples in the raw data graph.
|
|
|