public class RDFGraph
extends java.lang.Object
Constructor and Description |
---|
RDFGraph() |
Modifier and Type | Method and Description |
---|---|
void |
addTriple(RDFTriple triple) |
void |
dumpTriples(java.io.Writer w) |
java.util.Set<RDFResourceNode> |
getRootAnonymousNodes() |
java.util.List<RDFTriple> |
getSortedTriplesForSubject(RDFNode subject,
boolean sort) |
java.util.Set<RDFTriple> |
getTriplesForSubject(RDFNode subject)
Deprecated.
this method makes a defensive copy for each element in the map, but most uses of this only iterate over the results. Use getSortedTriplesForResult instead
|
boolean |
isAnonymousNodeSharedSubject(RDFResourceNode node) |
boolean |
isEmpty()
Determines if this graph is empty (i.e.
|
public boolean isEmpty()
true
if the graph contains triples, otherwise false
public void addTriple(RDFTriple triple)
triple
- triple to add@Deprecated public java.util.Set<RDFTriple> getTriplesForSubject(RDFNode subject)
subject
- node to searchpublic java.util.List<RDFTriple> getSortedTriplesForSubject(RDFNode subject, boolean sort)
subject
- sort
- public boolean isAnonymousNodeSharedSubject(RDFResourceNode node)
node
- node to searchpublic java.util.Set<RDFResourceNode> getRootAnonymousNodes()
public void dumpTriples(java.io.Writer w) throws java.io.IOException
w
- writer to write tojava.io.IOException
- if exceptions happen