Package ghidra.program.model.listing

# Interface DataTypeArchive

All Superinterfaces:
  `DataTypeManagerDomainObject`, `DataTypeManagerOwner`, `DomainObject`, `Undoable`, `UndoableDomainObject`

All Known Implementing Classes:
  `DataTypeArchiveDB`

public interface DataTypeArchive extends DataTypeManagerDomainObject
This interface represents the main entry point into an object which stores all information relating to a single data type archive.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final String`
  `CREATED_WITH_GHIDRA_VERSION`
  Name of ghidra version property
  `static final String`
  `DATA_TYPE_ARCHIVE_INFO`
  Name of data type archive information property list
  `static final String`
  `DATA_TYPE_ARCHIVE_SETTINGS`
  Name of data type archive settings property list
  `static final String`
  `DATE_CREATED`
  Name of date created property
  `static final Date`
  `JANUARY_1_1970`
  A date from January 1, 1970

  ### 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`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `DataTypeArchiveChangeSet`
  `getChanges()`
  Get the data type archive changes since the last save as a set of addresses.
  `Date`
  `getCreationDate()`
  Returns the creation date of this data type archive.
  `int`
  `getDefaultPointerSize()`
  Gets the default pointer size as it may be stored within the data type archive.
  `boolean`
  `hasExclusiveAccess()`
  Determine if this archive has exclusive-write access which may be neccessary for some operations.
  `void`
  `invalidate()`
  Invalidates any caching in a data type archive.
  `void`
  `setChanged(int type, Object oldValue, Object newValue)`
  Mark the state this data type archive as having changed and generate the event.
  `void`
  `setObjChanged(int type, Object affectedObj, Object oldValue, Object newValue)`
  Mark the state of a data type archive as having changed and generate the event.
  `void`
  `updateID()`

  ### Methods inherited from interface ghidra.app.merge.DataTypeManagerOwner

  `getDataTypeManager`

  ### Methods inherited from interface ghidra.framework.model.DomainObject

  `addCloseListener, addConsumer, addDomainFileListener, addListener, canLock, canSave, createPrivateEventQueue, flushEvents, flushPrivateEventQueue, forceLock, getConsumerList, getDescription, getDomainFile, getMetadata, getModificationNumber, getName, getOptions, getOptionsNames, isChangeable, isChanged, isClosed, isLocked, isSendingEvents, isTemporary, isUsedBy, lock, release, removeCloseListener, removeDomainFileListener, removeListener, removePrivateEventQueue, save, saveToPackedFile, setEventsEnabled, setName, setTemporary, unlock`

  ### Methods inherited from interface ghidra.framework.model.Undoable

  `addTransactionListener, canRedo, canUndo, clearUndo, getAllRedoNames, getAllUndoNames, getRedoName, getUndoName, redo, removeTransactionListener, undo`

  ### Methods inherited from interface ghidra.framework.model.UndoableDomainObject

  `addSynchronizedDomainObject, endTransaction, getCurrentTransactionInfo, getSynchronizedDomainObjects, hasTerminatedTransaction, openTransaction, releaseSynchronizedDomainObject, startTransaction, startTransaction, withTransaction, withTransaction`

- ## Field Details

  - ### DATA_TYPE_ARCHIVE_INFO

    static final String DATA_TYPE_ARCHIVE_INFO
    Name of data type archive information property list
    See Also:
      - Constant Field Values

  - ### DATA_TYPE_ARCHIVE_SETTINGS

    static final String DATA_TYPE_ARCHIVE_SETTINGS
    Name of data type archive settings property list
    See Also:
      - Constant Field Values

  - ### DATE_CREATED

    static final String DATE_CREATED
    Name of date created property
    See Also:
      - Constant Field Values

  - ### CREATED_WITH_GHIDRA_VERSION

    static final String CREATED_WITH_GHIDRA_VERSION
    Name of ghidra version property
    See Also:
      - Constant Field Values

  - ### JANUARY_1_1970

    static final Date JANUARY_1_1970
    A date from January 1, 1970

- ## Method Details

  - ### hasExclusiveAccess

    boolean hasExclusiveAccess()
    Determine if this archive has exclusive-write access which may be neccessary for some operations.
    Specified by:
      `hasExclusiveAccess` in interface `DomainObject`
    Returns:
      true if archive has exclusive-write access

  - ### getDefaultPointerSize

    int getDefaultPointerSize()
    Gets the default pointer size as it may be stored within the data type archive.
    Returns:
      default pointer size.

  - ### getCreationDate

    Date getCreationDate()
    Returns the creation date of this data type archive. existed, then Jan 1, 1970 is returned.
    Returns:
      the creation date of this data type archive

  - ### getChanges

    DataTypeArchiveChangeSet getChanges()
    Get the data type archive changes since the last save as a set of addresses.
    Returns:
      set of changed addresses within program.

  - ### setChanged

    void setChanged(int type, Object oldValue, Object newValue)
    Mark the state this data type archive as having changed and generate the event. Any or all parameters may be null.
    Parameters:
      `type` - event type
      `oldValue` - original value
      `newValue` - new value

  - ### setObjChanged

    void setObjChanged(int type, Object affectedObj, Object oldValue, Object newValue)
    Mark the state of a data type archive as having changed and generate the event. Any or all parameters may be null.
    Parameters:
      `type` - event type
      `affectedObj` - object that is the subject of the event
      `oldValue` - original value or an Object that is related to the event
      `newValue` - new value or an Object that is related to the the event

  - ### invalidate

    void invalidate()
    Invalidates any caching in a data type archive. NOTE: Over-using this method can adversely affect system performance.

  - ### updateID

    void updateID()