Package ghidra.program.model.util

# Interface PropertyMapManager

All Known Implementing Classes:
  `DBPropertyMapManager`, `DBTraceProgramViewPropertyMapManager`

public interface PropertyMapManager
Interface for managing a set of PropertyManagers.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `IntPropertyMap`
  `createIntPropertyMap(String propertyName)`
  Creates a new IntPropertyMap with the given name.
  `LongPropertyMap`
  `createLongPropertyMap(String propertyName)`
  Creates a new LongPropertyMap with the given name.
  `<T extends Saveable>
  ObjectPropertyMap<T>`
  `createObjectPropertyMap(String propertyName, Class<T> objectClass)`
  Creates a new ObjectPropertyMap with the given name.
  `StringPropertyMap`
  `createStringPropertyMap(String propertyName)`
  Creates a new StringPropertyMap with the given name.
  `VoidPropertyMap`
  `createVoidPropertyMap(String propertyName)`
  Creates a new VoidPropertyMap with the given name.
  `IntPropertyMap`
  `getIntPropertyMap(String propertyName)`
  Returns the IntPropertyMap associated with the given name.
  `LongPropertyMap`
  `getLongPropertyMap(String propertyName)`
  Returns the LongPropertyMap associated with the given name.
  `ObjectPropertyMap<? extends Saveable>`
  `getObjectPropertyMap(String propertyName)`
  Returns the ObjectPropertyMap associated with the given name.
  `PropertyMap<?>`
  `getPropertyMap(String propertyName)`
  Returns the PropertyMap with the given name or null if no PropertyMap exists with that name.
  `StringPropertyMap`
  `getStringPropertyMap(String propertyName)`
  Returns the StringPropertyMap associated with the given name.
  `VoidPropertyMap`
  `getVoidPropertyMap(String propertyName)`
  Returns the VoidPropertyMap associated with the given name.
  `Iterator<String>`
  `propertyManagers()`
  Returns an iterator over the names of all existing PropertyMaps sorted by name.
  `void`
  `removeAll(Address addr)`
  Removes any property at the given address from all defined PropertyMaps.
  `void`
  `removeAll(Address startAddr, Address endAddr, TaskMonitor monitor)`
  Removes all properties in the given range from all user defined PropertyMaps.
  `boolean`
  `removePropertyMap(String propertyName)`
  Removes the PropertyMap with the given name.

- ## Method Details

  - ### createIntPropertyMap

    IntPropertyMap createIntPropertyMap(String propertyName) throws DuplicateNameException
    Creates a new IntPropertyMap with the given name.
    Parameters:
      `propertyName` - the name for the new property.
    Returns:
      newly created integer object map
    Throws:
      `DuplicateNameException` - thrown if a PropertyMap already exists with that name.

  - ### createLongPropertyMap

    LongPropertyMap createLongPropertyMap(String propertyName) throws DuplicateNameException
    Creates a new LongPropertyMap with the given name.
    Parameters:
      `propertyName` - the name for the new property.
    Returns:
      newly created long object map
    Throws:
      `DuplicateNameException` - thrown if a PropertyMap already exists with that name.

  - ### createStringPropertyMap

    StringPropertyMap createStringPropertyMap(String propertyName) throws DuplicateNameException
    Creates a new StringPropertyMap with the given name.
    Parameters:
      `propertyName` - the name for the new property.
    Returns:
      newly created string object map
    Throws:
      `DuplicateNameException` - thrown if a PropertyMap already exists with that name.

  - ### createObjectPropertyMap

    <T extends Saveable> ObjectPropertyMap<T> createObjectPropertyMap(String propertyName, Class<T> objectClass) throws DuplicateNameException
    Creates a new ObjectPropertyMap with the given name.
    Type Parameters:
      `T` - `Saveable` property value type
    Parameters:
      `propertyName` - the name for the new property.
      `objectClass` - `Saveable` implementation class
    Returns:
      newly created `Saveable` object map
    Throws:
      `DuplicateNameException` - thrown if a PropertyMap already exists with that name.

  - ### createVoidPropertyMap

    VoidPropertyMap createVoidPropertyMap(String propertyName) throws DuplicateNameException
    Creates a new VoidPropertyMap with the given name.
    Parameters:
      `propertyName` - the name for the new property.
    Returns:
      newly created void map
    Throws:
      `DuplicateNameException` - thrown if a PropertyMap already exists with that name.

  - ### getPropertyMap

    PropertyMap<?> getPropertyMap(String propertyName)
    Returns the PropertyMap with the given name or null if no PropertyMap exists with that name.
    Parameters:
      `propertyName` - the name of the property to retrieve.
    Returns:
      existing map or null if not found

  - ### getIntPropertyMap

    IntPropertyMap getIntPropertyMap(String propertyName)
    Returns the IntPropertyMap associated with the given name.
    Parameters:
      `propertyName` - the name of the property to retrieve.
    Returns:
      existing map or null if not found
    Throws:
      `TypeMismatchException` - if a propertyMap named propertyName exists but is not an IntPropertyMap.

  - ### getLongPropertyMap

    LongPropertyMap getLongPropertyMap(String propertyName)
    Returns the LongPropertyMap associated with the given name.
    Parameters:
      `propertyName` - the name of the property to retrieve.
    Returns:
      existing map or null if not found
    Throws:
      `TypeMismatchException` - if a propertyMap named propertyName exists but is not an LongPropertyMap.

  - ### getStringPropertyMap

    StringPropertyMap getStringPropertyMap(String propertyName)
    Returns the StringPropertyMap associated with the given name.
    Parameters:
      `propertyName` - the name of the property to retrieve.
    Returns:
      existing map or null if not found
    Throws:
      `TypeMismatchException` - if a propertyMap named propertyName exists but is not a StringPropertyMap.

  - ### getObjectPropertyMap

    ObjectPropertyMap<? extends Saveable> getObjectPropertyMap(String propertyName)
    Returns the ObjectPropertyMap associated with the given name.
    Parameters:
      `propertyName` - the name of the property to retrieve.
    Returns:
      existing map or null if not found
    Throws:
      `TypeMismatchException` - if a propertyMap named propertyName exists but is not an ObjectPropertyMap.

  - ### getVoidPropertyMap

    VoidPropertyMap getVoidPropertyMap(String propertyName)
    Returns the VoidPropertyMap associated with the given name.
    Parameters:
      `propertyName` - the name of the property to retrieve.
    Returns:
      existing map or null if not found
    Throws:
      `TypeMismatchException` - if a propertyMap named propertyName exists but is not a VoidPropertyMap.

  - ### removePropertyMap

    boolean removePropertyMap(String propertyName)
    Removes the PropertyMap with the given name.
    Parameters:
      `propertyName` - the name of the property to remove.
    Returns:
      true if a PropertyMap with that name was found (and removed)

  - ### propertyManagers

    Iterator<String> propertyManagers()
    Returns an iterator over the names of all existing PropertyMaps sorted by name.

  - ### removeAll

    void removeAll(Address addr)
    Removes any property at the given address from all defined PropertyMaps.
    Parameters:
      `addr` - the address at which to remove all property values.

  - ### removeAll

    void removeAll(Address startAddr, Address endAddr, TaskMonitor monitor) throws CancelledException
    Removes all properties in the given range from all user defined PropertyMaps. The specified start and end addresses must form a valid range within a single `AddressSpace`.
    Parameters:
      `startAddr` - the first address in the range of addresses where propertie values are to be removed.
      `endAddr` - the last address in the range of addresses where propertie values are to be removed.
      `monitor` - monitors progress
    Throws:
      `CancelledException` - if the user cancelled the operation.