Class DBWithUserDataContentHandler<T extends DomainObjectAdapterDB>

java.lang.Object
ghidra.framework.data.DBContentHandler<T>
ghidra.framework.data.DBWithUserDataContentHandler<T>
Type Parameters:
T - DomainObjectAdapterDB implementation class
All Implemented Interfaces:
ContentHandler<T>, ExtensionPoint
Direct Known Subclasses:
ProgramContentHandler

public abstract class DBWithUserDataContentHandler<T extends DomainObjectAdapterDB> extends DBContentHandler<T>
DBContentHandler provides an abstract ContentHandler for domain object content which is stored within a database file. This class provides helper methods for working with database files.
  • Constructor Details

    • DBWithUserDataContentHandler

      public DBWithUserDataContentHandler()
  • Method Details

    • saveUserDataFile

      public final void saveUserDataFile(DomainObject associatedDomainObj, DBHandle userDbh, FileSystem userfs, TaskMonitor monitor) throws CancelledException, IOException
      Create user data file associated with existing content. This facilitates the lazy creation of the user data file.
      Parameters:
      associatedDomainObj - associated domain object corresponding to this content handler
      userDbh - user data handle
      userfs - private user data filesystem
      monitor - task monitor
      Throws:
      IOException - if an IO or access error occurs
      CancelledException - if operation is cancelled by user
    • removeUserDataFile

      public final void removeUserDataFile(FolderItem associatedItem, FileSystem userFilesystem) throws IOException
      Remove user data file associated with an existing folder item.
      Parameters:
      associatedItem - associated folder item
      userFilesystem - user data file system from which corresponding data should be removed.
      Throws:
      IOException - if an access error occurs
    • openAssociatedUserFile

      protected final DBHandle openAssociatedUserFile(String associatedFileID, String associatedContentType, FileSystem userfs, TaskMonitor monitor) throws IOException, CancelledException
      Open user data file associatedDbh
      Parameters:
      associatedFileID -
      associatedContentType -
      userfs -
      monitor -
      Returns:
      user data file database handle
      Throws:
      IOException
      CancelledException