Interface Dynamic

All Superinterfaces:
BuiltInDataType, DataType, ExtensionPoint
All Known Implementing Classes:
AbstractLeb128DataType, AbstractStringDataType, AIFFDataType, AlignmentDataType, AndroidElfRelocationTableDataType, AUDataType, BadDataType, BitmapResourceDataType, CountedDynamicDataType, DialogResourceDataType, DynamicDataType, GifDataType, GroupIconResourceDataType, HTMLResourceDataType, IconMaskResourceDataType, IconResourceDataType, IndexedDynamicDataType, JPEGDataType, MenuResourceDataType, MissingBuiltInDataType, MUIResourceDataType, PascalString255DataType, PascalStringDataType, PascalUnicodeDataType, PERichTableDataType, PEx64UnwindInfoDataType, PngDataType, RepeatCountDataType, RepeatedDynamicDataType, RepeatedStringDataType, RTTI0DataType, RTTI1DataType, RTTI2DataType, RTTI3DataType, RTTI4DataType, RTTIDataType, SignedLeb128DataType, StringDataType, StringUTF8DataType, StructuredDynamicDataType, TerminatedStringDataType, TerminatedUnicode32DataType, TerminatedUnicodeDataType, Unicode32DataType, UnicodeDataType, UnsignedLeb128DataType, WAVEDataType, WEVTResourceDataType

public interface Dynamic extends BuiltInDataType
A DataType class that must compute its length based upon actual data. This type may be referred to directly within a listing (including pointers). This type may only appear within a structure if canSpecifyLength() returns true. A pointer to this type can always appear within a structure. TypeDef to this data-type should not be allowed.
  • Method Details

    • getLength

      int getLength(MemBuffer buf, int maxLength)
      Compute the length for this data-type which corresponds to the specified memory location.
      Parameters:
      buf - memory location
      maxLength - maximum number of bytes to consume in computing length, or -1 for unspecified.
      Returns:
      data length or -1 if it could not be determined. Returned length may exceed maxLength if data-type does not supported constrained lengths.
    • canSpecifyLength

      default boolean canSpecifyLength()
      Determine if the length may be specified for an instanceof this datatype (e.g., Data, Array, DataTypeComponent, etc.).
      Returns:
      true if a user-specified length can be used, else false
    • getReplacementBaseType

      DataType getReplacementBaseType()
      Returns a suitable replacement base data-type for pointers and arrays when exporting to C code
      Returns:
      suitable base data-type for this Dynamic data-type