Class IntelHexRecord

java.lang.Object
ghidra.app.util.opinion.IntelHexRecord

public class IntelHexRecord extends Object
  • Field Details

    • MAX_RECORD_LENGTH

      public static final int MAX_RECORD_LENGTH
      See Also:
    • DATA_RECORD_TYPE

      public static final int DATA_RECORD_TYPE
      See Also:
    • END_OF_FILE_RECORD_TYPE

      public static final int END_OF_FILE_RECORD_TYPE
      See Also:
    • EXTENDED_SEGMENT_ADDRESS_RECORD_TYPE

      public static final int EXTENDED_SEGMENT_ADDRESS_RECORD_TYPE
      See Also:
    • START_SEGMENT_ADDRESS_RECORD

      public static final int START_SEGMENT_ADDRESS_RECORD
      See Also:
    • EXTENDED_LINEAR_ADDRESS_RECORD_TYPE

      public static final int EXTENDED_LINEAR_ADDRESS_RECORD_TYPE
      See Also:
    • START_LINEAR_ADDRESS_RECORD_TYPE

      public static final int START_LINEAR_ADDRESS_RECORD_TYPE
      See Also:
  • Constructor Details

    • IntelHexRecord

      public IntelHexRecord(int recordLength, int loadOffset, int recordType, byte[] data, int checksum)
      Use this constructor when reading, so you know if the record's checksum is correct.
      Parameters:
      recordLength -
      loadOffset -
      recordType -
      data -
      checksum -
    • IntelHexRecord

      public IntelHexRecord(int recordLength, int loadOffset, int recordType, byte[] data)
      Only use this constructor when writing...it computes the checksum for you (cheating)!
      Parameters:
      recordLength -
      loadOffset -
      recordType -
      data -
  • Method Details

    • getRecordLength

      public int getRecordLength()
    • getLoadOffset

      public int getLoadOffset()
    • getRecordType

      public int getRecordType()
    • getData

      public byte[] getData()
    • getDataString

      public String getDataString()
    • getReportedChecksum

      public int getReportedChecksum()
    • getActualChecksum

      public int getActualChecksum()
    • isReportedChecksumCorrect

      public boolean isReportedChecksumCorrect()
    • format

      public String format()
    • hashCode

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

      public boolean equals(Object obj)
      Overrides:
      equals in class Object