Class AddressBasedOpenCloseManager

java.lang.Object
ghidra.app.util.viewer.util.AddressBasedOpenCloseManager

public class AddressBasedOpenCloseManager extends Object
Class to maintain a simple open close/state for address locations. The default open/close state can be set and then a set of address is kept for the locations that are the opposite of the default.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    close(Address address)
    Sets the state at the given address to be "closed".
    void
    Sets all address to "closed" (Makes "closed" the default state and clears all individual settings.
    boolean
    isOpen(Address address)
    Checks if the state is "open" for the given address.
    boolean
    Checks if the default state is "open".
    void
    open(Address address)
    Sets the state at the given address to be "open".
    void
    Sets all address to "open" (Makes "open" the default state and clears all individual settings.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • AddressBasedOpenCloseManager

      public AddressBasedOpenCloseManager()
  • Method Details

    • isOpen

      public boolean isOpen(Address address)
      Checks if the state is "open" for the given address.
      Parameters:
      address - the address to test
      Returns:
      true if the state of the given address is "open"
    • open

      public void open(Address address)
      Sets the state at the given address to be "open".
      Parameters:
      address - the address to set "open"
    • close

      public void close(Address address)
      Sets the state at the given address to be "closed".
      Parameters:
      address - the address to set "closed"
    • isOpenByDefault

      public boolean isOpenByDefault()
      Checks if the default state is "open".
      Returns:
      true if the default state for addresses is "open"
    • openAll

      public void openAll()
      Sets all address to "open" (Makes "open" the default state and clears all individual settings.
    • closeAll

      public void closeAll()
      Sets all address to "closed" (Makes "closed" the default state and clears all individual settings.