Package ghidra.framework.task
Class GenericDomainObjectDB
- java.lang.Object
-
- ghidra.framework.data.DomainObjectAdapter
-
- ghidra.framework.data.DomainObjectAdapterDB
-
- ghidra.framework.task.GenericDomainObjectDB
-
- All Implemented Interfaces:
DBConstants
,ErrorHandler
,DomainObject
,Undoable
,UndoableDomainObject
public class GenericDomainObjectDB extends DomainObjectAdapterDB
-
-
Field Summary
-
Fields inherited from class ghidra.framework.data.DomainObjectAdapterDB
changeSet, dbh, NUM_UNDOS, options
-
Fields inherited from class ghidra.framework.data.DomainObjectAdapter
changed, changeSupportMap, DEFAULT_NAME, lock, metadata, name, temporary
-
Fields inherited from interface db.DBConstants
CREATE, READ_ONLY, UPDATE, UPGRADE
-
Fields inherited from interface ghidra.framework.model.DomainObject
DO_DOMAIN_FILE_CHANGED, DO_OBJECT_CLOSED, DO_OBJECT_ERROR, DO_OBJECT_RENAMED, DO_OBJECT_RESTORED, DO_OBJECT_SAVED, DO_PROPERTY_CHANGED, undoLock
-
-
Constructor Summary
Constructors Constructor Description GenericDomainObjectDB(java.lang.Object consumer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
endTransaction(int transactionID, boolean commit)
Terminate the specified transaction for this domain object.java.lang.String
getDescription()
Returns a word or short phrase that best describes or categorizes the object in terms that a user will understand.boolean
isChangeable()
Returns true if changes are permitted.int
startTransaction(java.lang.String description, AbortedTransactionListener listener)
Start a new transaction in order to make changes to this domain object.-
Methods inherited from class ghidra.framework.data.DomainObjectAdapterDB
addSynchronizedDomainObject, addTransactionListener, canLock, canRedo, canSave, canUndo, clearCache, clearUndo, clearUndo, close, dbError, flushWriteCache, forceLock, getChangeSet, getCurrentTransaction, getDBHandle, getOptions, getOptionsNames, getRedoName, getSynchronizedDomainObjects, getUndoName, getUndoStackDepth, getUserData, hasTerminatedTransaction, invalidateWriteCache, isChanged, isClosed, isLocked, loadMetadata, lock, performPropertyListAlterations, propertyChanged, redo, releaseSynchronizedDomainObject, removeTransactionListener, save, saveMetadata, saveToPackedFile, setChanged, startTransaction, undo, unlock, updateMetadata
-
Methods inherited from class ghidra.framework.data.DomainObjectAdapter
addCloseListener, addConsumer, addListener, checkExclusiveAccess, createPrivateEventQueue, fatalErrorOccurred, fireEvent, flushEvents, flushPrivateEventQueue, getAssociatedUserFilesystem, getChangeStatus, getConsumerList, getContentHandler, getDomainFile, getLock, getMetadata, getModificationNumber, getName, hasExclusiveAccess, isSendingEvents, isTemporary, isUsedBy, release, removeCloseListener, removeListener, removePrivateEventQueue, setDefaultContentClass, setDomainFile, setEventsEnabled, setName, setTemporary, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface ghidra.framework.model.DomainObject
addCloseListener, addConsumer, addListener, createPrivateEventQueue, flushEvents, flushPrivateEventQueue, getConsumerList, getDomainFile, getMetadata, getModificationNumber, getName, hasExclusiveAccess, isSendingEvents, isTemporary, isUsedBy, release, removeCloseListener, removeListener, removePrivateEventQueue, setEventsEnabled, setName, setTemporary
-
-
-
-
Method Detail
-
getDescription
public java.lang.String getDescription()
Description copied from interface:DomainObject
Returns a word or short phrase that best describes or categorizes the object in terms that a user will understand.- Specified by:
getDescription
in interfaceDomainObject
- Specified by:
getDescription
in classDomainObjectAdapter
- See Also:
DomainObject.getDescription()
-
isChangeable
public boolean isChangeable()
Description copied from interface:DomainObject
Returns true if changes are permitted.
-
startTransaction
public int startTransaction(java.lang.String description, AbortedTransactionListener listener)
Description copied from interface:UndoableDomainObject
Start a new transaction in order to make changes to this domain object. All changes must be made in the context of a transaction. If a transaction is already in progress, a sub-transaction of the current transaction will be returned.- Specified by:
startTransaction
in interfaceUndoableDomainObject
- Overrides:
startTransaction
in classDomainObjectAdapterDB
- Parameters:
description
- brief description of transactionlistener
- listener to be notified if the transaction is aborted.- Returns:
- transaction ID
- See Also:
UndoableDomainObject.startTransaction(java.lang.String)
-
endTransaction
public void endTransaction(int transactionID, boolean commit)
Description copied from interface:UndoableDomainObject
Terminate the specified transaction for this domain object.- Specified by:
endTransaction
in interfaceUndoableDomainObject
- Overrides:
endTransaction
in classDomainObjectAdapterDB
- Parameters:
transactionID
- transaction ID obtained from startTransaction methodcommit
- if true the changes made in this transaction will be marked for commit, if false this and any concurrent transaction will be rolled-back.- See Also:
UndoableDomainObject.endTransaction(int, boolean)
-
-