Class DBTraceProgramViewEquateTable

java.lang.Object
ghidra.trace.database.program.DBTraceProgramViewEquateTable
All Implemented Interfaces:
EquateTable

public class DBTraceProgramViewEquateTable extends Object implements EquateTable
  • Field Details

  • Constructor Details

    • DBTraceProgramViewEquateTable

      public DBTraceProgramViewEquateTable(DBTraceProgramView program)
  • Method Details

    • createEquate

      public Equate createEquate(String name, long value) throws DuplicateNameException, InvalidInputException
      Description copied from interface: EquateTable
      Creates a new equate
      Specified by:
      createEquate in interface EquateTable
      Parameters:
      name - the name to associate with the given value.
      value - the value to associate with the given name.
      Returns:
      the equate
      Throws:
      DuplicateNameException - thrown if name is already in use as an equate.
      InvalidInputException - if name contains blank characters, is zero length, or is null
    • removeEquate

      public boolean removeEquate(String name)
      Description copied from interface: EquateTable
      Removes the equate from the program.
      Specified by:
      removeEquate in interface EquateTable
      Parameters:
      name - the name of the equate to remove.
      Returns:
      true if the equate existed, false otherwise.
    • deleteAddressRange

      public void deleteAddressRange(Address start, Address end, TaskMonitor monitor) throws CancelledException
      Description copied from interface: EquateTable
      Removes all equates defined in the given range.
      Specified by:
      deleteAddressRange in interface EquateTable
      Parameters:
      start - start of the range
      end - end of the range
      monitor - task monitor to cancel the remove operation
      Throws:
      CancelledException - if the operation was cancelled.
    • doGetViewEquate

      protected DBTraceProgramViewEquate doGetViewEquate(DBTraceEquate equate)
    • getEquate

      public Equate getEquate(String name)
      Description copied from interface: EquateTable
      Returns the equate with the given name, null if no such equate exists
      Specified by:
      getEquate in interface EquateTable
      Parameters:
      name - the of the equate to be retrieved
      Returns:
      the equate
    • getEquate

      public Equate getEquate(Address reference, int opndPosition, long value)
      Description copied from interface: EquateTable
      Returns the first equate found that is associated with the given value at the given reference address and operand position;
      Specified by:
      getEquate in interface EquateTable
      Parameters:
      reference - address where the equate is used.
      opndPosition - the operand index of the operand where the equate is used.
      value - the value where the equate is used.
      Returns:
      the equate or null if there is no such equate.
    • getEquates

      public List<Equate> getEquates(Address reference, int opndPosition)
      Description copied from interface: EquateTable
      Returns the equates (one for each scalar) at the given reference address and operand position; For an instruction a given operand can have multiple scalars.
      Specified by:
      getEquates in interface EquateTable
      Parameters:
      reference - address where the equate is used.
      opndPosition - the operand index of the operand where the equate is used.
      Returns:
      the list of equates or empty list if there is no such equate.
    • getEquates

      public List<Equate> getEquates(Address reference)
      Description copied from interface: EquateTable
      Returns the equates (one for each scalar and opIndex) at the given reference address. For an instruction a given operand can have multiple scalars.
      Specified by:
      getEquates in interface EquateTable
      Parameters:
      reference - address where the equate is used.
      Returns:
      the list of equates or empty list if there is no such equate.
    • getEquateAddresses

      public AddressIterator getEquateAddresses()
      Description copied from interface: EquateTable
      Returns an address iterator over all the addresses where equates have been set.
      Specified by:
      getEquateAddresses in interface EquateTable
      Returns:
      the iterator
    • getEquates

      public List<Equate> getEquates(long value)
      Description copied from interface: EquateTable
      Returns all equates defined for value.
      Specified by:
      getEquates in interface EquateTable
      Parameters:
      value - the value to get all equates for.
      Returns:
      the equates
    • getEquates

      public Iterator<Equate> getEquates()
      Description copied from interface: EquateTable
      Returns an iterator over all equates.
      Specified by:
      getEquates in interface EquateTable
      Returns:
      the iterator
    • getEquateAddresses

      public AddressIterator getEquateAddresses(Address start)
      Description copied from interface: EquateTable
      Return an address iterator over each address with an equate reference starting at the start address.
      Specified by:
      getEquateAddresses in interface EquateTable
      Parameters:
      start - start address
      Returns:
      an AddressIterator over addresses with defined equate references
    • getEquateAddresses

      public AddressIterator getEquateAddresses(AddressSetView asv)
      Description copied from interface: EquateTable
      Return an address iterator over each address with an equate reference that is in the specified address set.
      Specified by:
      getEquateAddresses in interface EquateTable
      Parameters:
      asv - the address set
      Returns:
      AddressIterator over addresses with defined equate references