Class AddressPreviewTableModel

All Implemented Interfaces:
ConfigurableColumnTableModel, DynamicColumnTableModel<Address>, RowObjectFilterModel<Address>, RowObjectTableModel<Address>, SelectionStorage<Address>, SortedTableModel, VariableColumnTableModel, ProgramTableModel, Serializable, EventListener, ChangeListener, TableModel
Direct Known Subclasses:
AddressArrayTableModel, AddressSetTableModel, CustomLoadingAddressTableModel

public abstract class AddressPreviewTableModel extends AddressBasedTableModel<Address>
Table model that shows a location, label, and a preview column to show a preview of the code unit. The location can be in a memory address, a stack address, or a register address. The label is the primary symbol at the address, if one exists. Use this model when you have a list of addresses to build up dynamically.
See Also:
  • Constructor Details

    • AddressPreviewTableModel

      protected AddressPreviewTableModel(String modelName, ServiceProvider serviceProvider, Program program, TaskMonitor monitor)
      Constructor.
      Parameters:
      modelName - the name of the model (used for the title)
      serviceProvider - from which to get services
      program - the program upon which this model is being used
      monitor - the monitor to use for tracking progress and cancelling; may be null
    • AddressPreviewTableModel

      protected AddressPreviewTableModel(String modelName, ServiceProvider serviceProvider, Program program, TaskMonitor monitor, boolean loadIncrementally)
      Constructor.
      Parameters:
      modelName - the name of the model (used for the title)
      serviceProvider - from which to get services
      program - the program upon which this model is being used
      monitor - the monitor to use for tracking progress and cancelling; may be null
      loadIncrementally - true signals to show table results as they come in
  • Method Details

    • setSelectionSize

      public void setSelectionSize(int size)
      Sets the size of the selections generated by this model when asked to create program selections. For example, some clients know that each table row represents a contiguous range of 4 addresses. In this case, when the user makes a selection, that client wants the selection to be 4 addresses, starting at the address in the given table row.
      Parameters:
      size - the size of the selections generated by this model when asked to create program selections.
    • getAddress

      public Address getAddress(int row)
      Specified by:
      getAddress in class AddressBasedTableModel<Address>
    • getProgramSelection

      public ProgramSelection getProgramSelection(int[] rows)
      Description copied from interface: ProgramTableModel
      Returns a program selection corresponding to the specified row index array. This array will contain the currently selected rows.
      Specified by:
      getProgramSelection in interface ProgramTableModel
      Overrides:
      getProgramSelection in class AddressBasedTableModel<Address>
      Parameters:
      rows - the currently selected rows.
      Returns:
      a program selection