Package ghidra.trace.database

# Class DBTraceChangeSet

java.lang.Object
ghidra.trace.database.DBTraceChangeSet

All Implemented Interfaces:
  `DBChangeSet`, `DomainObjectDBChangeSet`, `ChangeSet`, `DataTypeChangeSet`, `TraceChangeSet`

public class DBTraceChangeSet extends Object implements TraceChangeSet, DomainObjectDBChangeSet

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DBTraceChangeSet()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `categoryAdded(long id)`
  adds the data type category id to the list of categories that have been added.
  `void`
  `categoryChanged(long id)`
  adds the data type category id to the list of categories that have changed.
  `void`
  `clearUndo()`
  Clears the undo/redo stack.
  `void`
  `clearUndo(boolean isCheckedOut)`
  Resets the change sets after a save.
  `void`
  `dataTypeAdded(long id)`
  Adds the data type ID to the list of added data types.
  `void`
  `dataTypeChanged(long id)`
  Adds the dataType ID to the list of changed data types.
  `void`
  `endTransaction(boolean commit)`
  End change data transaction.
  `long[]`
  `getCategoryAdditions()`
  returns the list of category IDs that have been added.
  `long[]`
  `getCategoryChanges()`
  returns the list of category IDs that have changed.
  `long[]`
  `getDataTypeAdditions()`
  returns a list of data type IDs that have been added.
  `long[]`
  `getDataTypeChanges()`
  returns a list of data type IDs that have changed.
  `long[]`
  `getSourceArchiveAdditions()`
  returns a list of data type source archive IDs that have been added.
  `long[]`
  `getSourceArchiveChanges()`
  returns a list of data type source archive IDs that have changed.
  `void`
  `read(DBHandle dbh)`
  Read into this change set from the specified database handle.
  `void`
  `redo()`
  Redo the change data transaction associated the last Undo.
  `void`
  `setMaxUndos(int maxUndos)`
  Set the undo/redo stack depth
  `void`
  `sourceArchiveAdded(long id)`
  Adds the data type source archive ID to the list of added data type archive IDs.
  `void`
  `sourceArchiveChanged(long id)`
  Adds the data type source archive ID to the list of changed data type archive IDs.
  `void`
  `startTransaction()`
  Start change data transaction.
  `void`
  `undo()`
  Undo the last change data transaction
  `void`
  `write(DBHandle dbh, boolean isRecoverySave)`
  Write this change set to the specified database handle.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### DBTraceChangeSet

    public DBTraceChangeSet()

- ## Method Details

  - ### read

    public void read(DBHandle dbh) throws IOException
    Description copied from interface: `DBChangeSet`
    Read into this change set from the specified database handle. The database handle will not be retained and should be closed by the invoker of this method.
    Specified by:
      `read` in interface `DBChangeSet`
    Parameters:
      `dbh` - database handle
    Throws:
      `IOException` - if IO error occurs

  - ### write

    public void write(DBHandle dbh, boolean isRecoverySave) throws IOException
    Description copied from interface: `DBChangeSet`
    Write this change set to the specified database handle. The database handle will not be retained and should be closed by the invoker of this method.
    Specified by:
      `write` in interface `DBChangeSet`
    Parameters:
      `dbh` - database handle
      `isRecoverySave` - true if this write is because of a recovery snapshot or false if due to a user save action.
    Throws:
      `IOException` - if IO error occurs

  - ### clearUndo

    public void clearUndo(boolean isCheckedOut)
    Description copied from interface: `DomainObjectDBChangeSet`
    Resets the change sets after a save.
    Specified by:
      `clearUndo` in interface `DomainObjectDBChangeSet`

  - ### undo

    public void undo()
    Description copied from interface: `DomainObjectDBChangeSet`
    Undo the last change data transaction
    Specified by:
      `undo` in interface `DomainObjectDBChangeSet`

  - ### redo

    public void redo()
    Description copied from interface: `DomainObjectDBChangeSet`
    Redo the change data transaction associated the last Undo.
    Specified by:
      `redo` in interface `DomainObjectDBChangeSet`

  - ### setMaxUndos

    public void setMaxUndos(int maxUndos)
    Description copied from interface: `DomainObjectDBChangeSet`
    Set the undo/redo stack depth
    Specified by:
      `setMaxUndos` in interface `DomainObjectDBChangeSet`
    Parameters:
      `maxUndos` - the maximum numbder of undo

  - ### clearUndo

    public void clearUndo()
    Description copied from interface: `DomainObjectDBChangeSet`
    Clears the undo/redo stack.
    Specified by:
      `clearUndo` in interface `DomainObjectDBChangeSet`

  - ### startTransaction

    public void startTransaction()
    Description copied from interface: `DomainObjectDBChangeSet`
    Start change data transaction.
    Specified by:
      `startTransaction` in interface `DomainObjectDBChangeSet`

  - ### endTransaction

    public void endTransaction(boolean commit)
    Description copied from interface: `DomainObjectDBChangeSet`
    End change data transaction.
    Specified by:
      `endTransaction` in interface `DomainObjectDBChangeSet`
    Parameters:
      `commit` - if true transaction data is committed, otherwise transaction data is discarded

  - ### dataTypeChanged

    public void dataTypeChanged(long id)
    Description copied from interface: `DataTypeChangeSet`
    Adds the dataType ID to the list of changed data types.
    Specified by:
      `dataTypeChanged` in interface `DataTypeChangeSet`

  - ### dataTypeAdded

    public void dataTypeAdded(long id)
    Description copied from interface: `DataTypeChangeSet`
    Adds the data type ID to the list of added data types.
    Specified by:
      `dataTypeAdded` in interface `DataTypeChangeSet`
    Parameters:
      `id` -

  - ### getDataTypeChanges

    public long[] getDataTypeChanges()
    Description copied from interface: `DataTypeChangeSet`
    returns a list of data type IDs that have changed.
    Specified by:
      `getDataTypeChanges` in interface `DataTypeChangeSet`

  - ### getDataTypeAdditions

    public long[] getDataTypeAdditions()
    Description copied from interface: `DataTypeChangeSet`
    returns a list of data type IDs that have been added.
    Specified by:
      `getDataTypeAdditions` in interface `DataTypeChangeSet`

  - ### categoryChanged

    public void categoryChanged(long id)
    Description copied from interface: `DataTypeChangeSet`
    adds the data type category id to the list of categories that have changed.
    Specified by:
      `categoryChanged` in interface `DataTypeChangeSet`

  - ### categoryAdded

    public void categoryAdded(long id)
    Description copied from interface: `DataTypeChangeSet`
    adds the data type category id to the list of categories that have been added.
    Specified by:
      `categoryAdded` in interface `DataTypeChangeSet`

  - ### getCategoryChanges

    public long[] getCategoryChanges()
    Description copied from interface: `DataTypeChangeSet`
    returns the list of category IDs that have changed.
    Specified by:
      `getCategoryChanges` in interface `DataTypeChangeSet`

  - ### getCategoryAdditions

    public long[] getCategoryAdditions()
    Description copied from interface: `DataTypeChangeSet`
    returns the list of category IDs that have been added.
    Specified by:
      `getCategoryAdditions` in interface `DataTypeChangeSet`

  - ### sourceArchiveChanged

    public void sourceArchiveChanged(long id)
    Description copied from interface: `DataTypeChangeSet`
    Adds the data type source archive ID to the list of changed data type archive IDs.
    Specified by:
      `sourceArchiveChanged` in interface `DataTypeChangeSet`

  - ### sourceArchiveAdded

    public void sourceArchiveAdded(long id)
    Description copied from interface: `DataTypeChangeSet`
    Adds the data type source archive ID to the list of added data type archive IDs.
    Specified by:
      `sourceArchiveAdded` in interface `DataTypeChangeSet`
    Parameters:
      `id` - the data type source archive ID

  - ### getSourceArchiveChanges

    public long[] getSourceArchiveChanges()
    Description copied from interface: `DataTypeChangeSet`
    returns a list of data type source archive IDs that have changed.
    Specified by:
      `getSourceArchiveChanges` in interface `DataTypeChangeSet`

  - ### getSourceArchiveAdditions

    public long[] getSourceArchiveAdditions()
    Description copied from interface: `DataTypeChangeSet`
    returns a list of data type source archive IDs that have been added.
    Specified by:
      `getSourceArchiveAdditions` in interface `DataTypeChangeSet`