Package net.ontopia.topicmaps.impl.rdbms
Class RDBMSTopicMapReference
java.lang.Object
net.ontopia.topicmaps.entry.AbstractTopicMapReference
net.ontopia.topicmaps.impl.rdbms.RDBMSTopicMapReference
- All Implemented Interfaces:
AutoCloseable,TopicMapReferenceIF
INTERNAL: RDBMS database topic map reference.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected LocatorIFstatic final Stringstatic final Stringstatic final Stringprotected StorePoolableObjectFactoryprotected org.apache.commons.pool2.impl.GenericObjectPoolprotected RDBMSTopicMapStoreprotected StorageIFprotected longFields inherited from class net.ontopia.topicmaps.entry.AbstractTopicMapReference
deleted, id, isopen, listeners, source, title, topic_listeners -
Constructor Summary
ConstructorsConstructorDescriptionRDBMSTopicMapReference(String _id, String _title, StorageIF _storage, long _topicmap_id, LocatorIF _base_address) -
Method Summary
Modifier and TypeMethodDescriptionprotected RDBMSTopicMapStore_createStore(boolean readonly) voidclear()EXPERIMENTAL: Closes all open stores and clears the topic map by removing all data.voidclose()PUBLIC: Closes all open stores and the reference itself.createStore(boolean readonly) PUBLIC: Creates a topic map store that lets you access the referenced topic map.voiddelete()PUBLIC: Closes all open stores and deletes the topic map.INTERNAL: Returns the base address locator to be used when loading the topic map.longprotected voidinit()voidopen()PUBLIC: Opens the reference.voidsetBaseAddress(LocatorIF base_address) INTERNAL: Sets the base address locator to be used when loading the topic map and persists it in the database.voidPUBLIC: Sets the title of the reference.voidstoreClosed(TopicMapStoreIF store) INTERNAL: Callback from the specified TopicMapStoreIF after it has been closed.toString()voidwriteReport(Writer out, boolean dumpCaches) Methods inherited from class net.ontopia.topicmaps.entry.AbstractTopicMapReference
addTopicListener, getId, getSource, getTitle, getTopicListeners, isDeleted, isOpen, makeListenerArray, registerTopicListeners, removeTopicListener, setId, setSource, setTopicListeners
-
Field Details
-
EXHAUSED_BLOCK
- See Also:
-
EXHAUSED_GROW
- See Also:
-
EXHAUSED_FAIL
- See Also:
-
storage
-
topicmap_id
protected long topicmap_id -
base_address
-
ofactory
-
pool
protected org.apache.commons.pool2.impl.GenericObjectPool pool -
rostore
-
-
Constructor Details
-
RDBMSTopicMapReference
-
-
Method Details
-
_createStore
-
init
protected void init() -
open
public void open()Description copied from interface:TopicMapReferenceIFPUBLIC: Opens the reference.- Specified by:
openin interfaceTopicMapReferenceIF- Overrides:
openin classAbstractTopicMapReference
-
createStore
Description copied from interface:TopicMapReferenceIFPUBLIC: Creates a topic map store that lets you access the referenced topic map.- Specified by:
createStorein interfaceTopicMapReferenceIF- Specified by:
createStorein classAbstractTopicMapReference
-
setTitle
Description copied from interface:TopicMapReferenceIFPUBLIC: Sets the title of the reference.- Specified by:
setTitlein interfaceTopicMapReferenceIF- Overrides:
setTitlein classAbstractTopicMapReference
-
getBaseAddress
INTERNAL: Returns the base address locator to be used when loading the topic map. -
setBaseAddress
INTERNAL: Sets the base address locator to be used when loading the topic map and persists it in the database. -
close
public void close()Description copied from interface:TopicMapReferenceIFPUBLIC: Closes all open stores and the reference itself. Note that topic map stores created through this reference are closed and dereferenced when the reference is closed. The reference can be reopened after it has been closed.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceTopicMapReferenceIF- Overrides:
closein classAbstractTopicMapReference
-
clear
public void clear()Description copied from interface:TopicMapReferenceIFEXPERIMENTAL: Closes all open stores and clears the topic map by removing all data. The reference is closed before the topic map is deleted. The reference can be reopened after the topic map has been deleted.- Specified by:
clearin interfaceTopicMapReferenceIF- Overrides:
clearin classAbstractTopicMapReference
-
delete
public void delete()Description copied from interface:TopicMapReferenceIFPUBLIC: Closes all open stores and deletes the topic map. The reference is closed before the topic map is deleted. The reference cannot be reopened after the topic map has been deleted.- Specified by:
deletein interfaceTopicMapReferenceIF- Overrides:
deletein classAbstractTopicMapReference
-
toString
-
getTopicMapId
public long getTopicMapId() -
storeClosed
Description copied from interface:TopicMapReferenceIFINTERNAL: Callback from the specified TopicMapStoreIF after it has been closed. Warning: Intended for internal use only.- Specified by:
storeClosedin interfaceTopicMapReferenceIF- Overrides:
storeClosedin classAbstractTopicMapReference
-
writeReport
- Throws:
IOException
-