|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TableManager
Provides thread-safe read/write access to the tables used by MPTStore. Implementations of this interface will typically cache the predicate-to-table mappings in memory, and will always persist them to the database.
Method Summary | |
---|---|
int |
dropAllPredicateTables()
Drop all predicate tables and mappings, effectively re-initializing the triplestore. |
int |
dropEmptyPredicateTables()
Drop all unused predicate tables and mappings. |
java.lang.String |
getOrMapTableFor(PredicateNode predicate)
Get the name of the table reserved for relationships of the given type. |
PredicateNode |
getPredicateFor(java.lang.String table)
Get the predicate that's mapped to the given table, if such a mapping exists. |
java.util.Set<PredicateNode> |
getPredicates()
Get the set of predicates for which a table mapping exists. |
java.lang.String |
getTableFor(PredicateNode predicate)
Get the name of the table reserved for relationships of the given type, if it exists. |
java.util.Set<java.lang.String> |
getTables()
Get the set of tables that store per-predicate relationships. |
Method Detail |
---|
java.lang.String getOrMapTableFor(PredicateNode predicate) throws java.sql.SQLException
If such a table does not yet exist, it will be automatically created and permanently associated with the given predicate.
predicate
- The type of relationship.
null
.
java.sql.SQLException
- if a database error occurs while the table isjava.lang.String getTableFor(PredicateNode predicate)
predicate
- The type of relationship.
null
if no such predicate exists in the graph.PredicateNode getPredicateFor(java.lang.String table)
table
- The name of the table.
null
if no such mapping exists.java.util.Set<java.lang.String> getTables()
java.util.Set<PredicateNode> getPredicates()
int dropEmptyPredicateTables() throws java.sql.SQLException
java.sql.SQLException
- if a database error occured during the operation.int dropAllPredicateTables() throws java.sql.SQLException
java.sql.SQLException
- if a database error occured during the operation.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |