
public interface Graph extends Serializable, Comparable<Graph>
| Modifier and Type | Method and Description |
|---|---|
void |
beginTransaction()
Starts a new transaction.
|
void |
clear()
Clears all data from the graph.
|
void |
close()
Closes the graph.
|
void |
commitTransaction()
Commits the changes made by the transaction.
|
boolean |
containsStatement(XDIStatement XDIstatement)
Check if a statement exists in this graph.
|
long |
getAllStatementCount()
Returns the number of all statements in this graph.
|
ReadOnlyIterator<Statement> |
getAllStatements()
Gets all statements in this graph.
|
ContextNode |
getDeepContextNode(XDIAddress contextNodeXDIAddress) |
ContextNode |
getDeepContextNode(XDIAddress contextNodeXDIAddress,
boolean subgraph) |
LiteralNode |
getDeepLiteralNode(XDIAddress literalNodeXDIAddress) |
LiteralNode |
getDeepLiteralNode(XDIAddress literalNodeXDIAddress,
boolean subgraph) |
Node |
getDeepNode(XDIAddress nodeXDIAddress)
Returns a node at an arbitrary level of the graph.
|
Node |
getDeepNode(XDIAddress nodeXDIAddress,
boolean subgraph)
Returns a node at an arbitrary level of the graph.
|
GraphFactory |
getGraphFactory()
Gets the graph factory that created this graph.
|
String |
getIdentifier()
Returns an optional identifier to distinguish graphs from one another.
|
ContextNode |
getRootContextNode()
Gets the local root context node of this graph.
|
ContextNode |
getRootContextNode(boolean subgraph)
Gets the local root context node of this graph.
|
Statement |
getStatement(XDIStatement XDIstatement)
Gets a statement in this graph.
|
boolean |
isEmpty()
Checks if the graph is empty.
|
void |
rollbackTransaction()
Rolls back the changes made by the transaction.
|
ContextNode |
setDeepContextNode(XDIAddress contextNodeXDIAddress) |
LiteralNode |
setDeepLiteralNode(XDIAddress literalNodeXDIAddress) |
Node |
setDeepNode(XDIAddress nodeXDIAddress)
Create a new node at an arbitrary level of the graph, or returns an existing node.
|
Statement |
setStatement(XDIStatement XDIstatement)
Sets a statement in this graph.
|
boolean |
supportsTransactions()
Check if this graph supports transactions.
|
String |
toString(MimeType mimeType)
Converts the graph to a string in the given MIME type.
|
String |
toString(String format,
Properties parameters)
Converts the graph to a string in the given serialization format.
|
compareToGraphFactory getGraphFactory()
String getIdentifier()
ContextNode getRootContextNode(boolean subgraph)
subgraph - This is simply a hint to the implementation whether
child context nodes will subsequently be requested. Implementations may
or may not actually use this parameter.ContextNode getRootContextNode()
void close()
void clear()
boolean isEmpty()
String toString(String format, Properties parameters)
format - The serialization format.parameters - Parameters for the serialization.String toString(MimeType mimeType)
mimeType - The MIME type.Node setDeepNode(XDIAddress nodeXDIAddress)
nodeXDIAddress - The relative address of the new or existing node.ContextNode setDeepContextNode(XDIAddress contextNodeXDIAddress)
LiteralNode setDeepLiteralNode(XDIAddress literalNodeXDIAddress)
Node getDeepNode(XDIAddress nodeXDIAddress, boolean subgraph)
nodeXDIAddress - The relative address of the node.subgraph - This is simply a hint to the implementation whether
child context nodes will subsequently be requested. Implementations may
or may not actually use this parameter.ContextNode getDeepContextNode(XDIAddress contextNodeXDIAddress, boolean subgraph)
LiteralNode getDeepLiteralNode(XDIAddress literalNodeXDIAddress, boolean subgraph)
Node getDeepNode(XDIAddress nodeXDIAddress)
nodeXDIAddress - The relative address of the node.ContextNode getDeepContextNode(XDIAddress contextNodeXDIAddress)
LiteralNode getDeepLiteralNode(XDIAddress literalNodeXDIAddress)
Statement setStatement(XDIStatement XDIstatement)
Statement getStatement(XDIStatement XDIstatement)
ReadOnlyIterator<Statement> getAllStatements()
boolean containsStatement(XDIStatement XDIstatement)
long getAllStatementCount()
boolean supportsTransactions()
void beginTransaction()
void commitTransaction()
void rollbackTransaction()
Copyright © 2015. All Rights Reserved.