Package org.apache.jena.mem
Class NodeToTriplesMapBase
- java.lang.Object
-
- org.apache.jena.mem.NodeToTriplesMapBase
-
- Direct Known Subclasses:
NodeToTriplesMap
,NodeToTriplesMapMem
public abstract class NodeToTriplesMapBase extends java.lang.Object
A base class for in-memory graphs
-
-
Constructor Summary
Constructors Constructor Description NodeToTriplesMapBase(Triple.Field indexField, Triple.Field f2, Triple.Field f3)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract boolean
add(Triple t)
Addt
to this NTM; the nodeo
must be the index node of the triple.void
clear()
Clear this NTM; it will contain no triples.abstract boolean
contains(Triple t)
Answer true iff this NTM contains the concrete triplet
.abstract boolean
containsBySameValueAs(Triple t)
java.util.Iterator<java.lang.Object>
domain()
The values (usually nodes) which appear in the index position of the stored triples; useful for eg listSubjects().boolean
isEmpty()
ExtendedIterator<Triple>
iterateAll()
Answer an iterator over all the triples in this NTM.abstract java.util.Iterator<Triple>
iterator(java.lang.Object o, HashCommon.NotifyEmpty container)
abstract ExtendedIterator<Triple>
iterator(Node index, Node n2, Node n3)
abstract java.util.Iterator<Triple>
iteratorForIndexed(java.lang.Object y)
Answer an iterator over all the triples that are indexed by the itemy
.abstract boolean
remove(Triple t)
Removet
from this NTM.void
removedOneViaIterator()
int
size()
-
-
-
Field Detail
-
bunchMap
public BunchMap bunchMap
The map from nodes to Bunch(Triple).
-
-
Constructor Detail
-
NodeToTriplesMapBase
public NodeToTriplesMapBase(Triple.Field indexField, Triple.Field f2, Triple.Field f3)
-
-
Method Detail
-
add
public abstract boolean add(Triple t)
Addt
to this NTM; the nodeo
must be the index node of the triple. Answertrue
iff the triple was not previously in the set, ie, it really truly has been added.
-
remove
public abstract boolean remove(Triple t)
Removet
from this NTM. Answertrue
iff the triple was previously in the set, ie, it really truly has been removed.
-
iterator
public abstract java.util.Iterator<Triple> iterator(java.lang.Object o, HashCommon.NotifyEmpty container)
-
contains
public abstract boolean contains(Triple t)
Answer true iff this NTM contains the concrete triplet
.
-
containsBySameValueAs
public abstract boolean containsBySameValueAs(Triple t)
-
domain
public final java.util.Iterator<java.lang.Object> domain()
The values (usually nodes) which appear in the index position of the stored triples; useful for eg listSubjects().
-
clear
public void clear()
Clear this NTM; it will contain no triples.
-
size
public int size()
-
removedOneViaIterator
public void removedOneViaIterator()
-
isEmpty
public boolean isEmpty()
-
iterator
public abstract ExtendedIterator<Triple> iterator(Node index, Node n2, Node n3)
-
iteratorForIndexed
public abstract java.util.Iterator<Triple> iteratorForIndexed(java.lang.Object y)
Answer an iterator over all the triples that are indexed by the itemy
. Note thaty
need not be a Node (because of indexing values).
-
iterateAll
public ExtendedIterator<Triple> iterateAll()
Answer an iterator over all the triples in this NTM.
-
-