Class SpacerFieldLocation

All Implemented Interfaces:
Cloneable, Comparable<ProgramLocation>

public class SpacerFieldLocation extends CodeUnitLocation
The SpacerFieldLocation class contains specific location information within a spacer field of a CodeUnitLocation object.
  • Constructor Details

    • SpacerFieldLocation

      public SpacerFieldLocation(Program program, Address addr, int[] componentPath, int charOffset, String text)
      Construct a new SpacerFieldLocation.
      Parameters:
      program - the program of the location
      addr - the address of the codeunit.
      componentPath - the componentPath of the codeUnit
      charOffset - the character position on the row of the location.
      text - the constant text in this spacer.
    • SpacerFieldLocation

      public SpacerFieldLocation()
      Should only be used by XML restoration.
  • Method Details

    • getText

      public String getText()
      Returns the text of the Spacer field containing this location.
    • toString

      public String toString()
      returns a String representation of this location.
      Overrides:
      toString in class ProgramLocation
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class ProgramLocation
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class ProgramLocation
    • restoreState

      public void restoreState(Program p, SaveState obj)
      Description copied from class: ProgramLocation
      Restore this program location using the given program and save state object.
      Overrides:
      restoreState in class ProgramLocation
      Parameters:
      p - program to restore from
      obj - the save state to restore from
    • saveState

      public void saveState(SaveState obj)
      Description copied from class: ProgramLocation
      Save this program location to the given save state object.
      Overrides:
      saveState in class ProgramLocation
      Parameters:
      obj - the save state object for saving the location