Package org.apache.jena.sparql.core.mem
Class HexTable
- java.lang.Object
-
- org.apache.jena.sparql.core.mem.HexTable
-
- All Implemented Interfaces:
QuadTable,TransactionalComponent,TupleTable<Quad>
public class HexTable extends java.lang.Object implements QuadTable
A six-wayQuadTableusing all of the available forms inQuadTableForm. This class binds together all of the enumerated values inenum QuadTableForm, each of which implementsQuadTable, into one implementation ofQuadTablethat selects the most useful index form(s) for any given operation.
-
-
Constructor Summary
Constructors Constructor Description HexTable()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(Quad q)Add a tuple to the tablevoidbegin(ReadWrite rw)Start either a READ or WRITE transactionvoidclear()Clear all tuples from this table.voidcommit()Commit a transaction - finish the transaction and make any changes permanent (if a "write" transaction)voiddelete(Quad q)Remove a tuple from the tablevoidend()Finish the transaction - if a write transaction and commit() has not been called, then abortjava.util.stream.Stream<Quad>find(Node g, Node s, Node p, Node o)Search the table using a pattern of slots.java.util.stream.Stream<Quad>findInUnionGraph(Node s, Node p, Node o)java.util.stream.Stream<Node>listGraphNodes()Discover the graphs named in the table-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.jena.sparql.core.mem.TupleTable
abort
-
-
-
-
Method Detail
-
find
public java.util.stream.Stream<Quad> find(Node g, Node s, Node p, Node o)
Description copied from interface:QuadTableSearch the table using a pattern of slots.Node.ANYornullwill work as a wildcard.
-
add
public void add(Quad q)
Description copied from interface:TupleTableAdd a tuple to the table- Specified by:
addin interfaceTupleTable<Quad>- Parameters:
q- the tuple to add
-
delete
public void delete(Quad q)
Description copied from interface:TupleTableRemove a tuple from the table- Specified by:
deletein interfaceTupleTable<Quad>- Parameters:
q- the tuple to remove
-
listGraphNodes
public java.util.stream.Stream<Node> listGraphNodes()
Description copied from interface:QuadTableDiscover the graphs named in the table- Specified by:
listGraphNodesin interfaceQuadTable- Returns:
- an
Streamof graph names used in this table
-
findInUnionGraph
public java.util.stream.Stream<Quad> findInUnionGraph(Node s, Node p, Node o)
- Specified by:
findInUnionGraphin interfaceQuadTable
-
begin
public void begin(ReadWrite rw)
Description copied from interface:TransactionalComponentStart either a READ or WRITE transaction- Specified by:
beginin interfaceTransactionalComponent
-
end
public void end()
Description copied from interface:TransactionalComponentFinish the transaction - if a write transaction and commit() has not been called, then abort- Specified by:
endin interfaceTransactionalComponent
-
commit
public void commit()
Description copied from interface:TransactionalComponentCommit a transaction - finish the transaction and make any changes permanent (if a "write" transaction)- Specified by:
commitin interfaceTransactionalComponent
-
clear
public void clear()
Description copied from interface:TupleTableClear all tuples from this table.- Specified by:
clearin interfaceQuadTable- Specified by:
clearin interfaceTupleTable<Quad>
-
-