java.lang.Object
org.apache.jena.graph.impl.WrappedGraph
org.apache.jena.ontology.models.GraphRefCount
- All Implemented Interfaces:
Graph,GraphWithPerform
GraphMemRefCount - a base class for GraphMemValue
GraphMemRefCount maintains a reference count, set to one when it is created, and
incremented by the method openAgain(). When the graph is closed, the
count is decremented, and when it reaches 0, the tables are trashed and
GraphBase.close() called. Thus in normal use one close is enough, but GraphMakers
using GraphMems can arrange to re-use the same named graph.
-
Field Summary
Fields inherited from interface org.apache.jena.graph.Graph
emptyGraph -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Close this graph; if it is now fully closed, destroy its resources and run the GraphBase close.voiddestroy()Sub-classes over-ride this method to release any resources they no longer need once fully closed.Note a re-opening of this graph by incrementing the count.Methods inherited from class org.apache.jena.graph.impl.WrappedGraph
add, clear, contains, contains, delete, find, find, getEventManager, getPrefixMapping, getTransactionHandler, getWrapped, isClosed, isEmpty, isIsomorphicWith, performAdd, performDelete, remove, size
-
Method Details
-
openAgain
Note a re-opening of this graph by incrementing the count. Answer this Graph. -
destroy
public void destroy()Sub-classes over-ride this method to release any resources they no longer need once fully closed. -
close
public void close()Close this graph; if it is now fully closed, destroy its resources and run the GraphBase close.- Specified by:
closein interfaceGraph- Overrides:
closein classWrappedGraph
-