Package ghidra.app.util.bin.format.som

# Class SomExportEntry

java.lang.Object
ghidra.app.util.bin.format.som.SomExportEntry

All Implemented Interfaces:
  `StructConverter`

public class SomExportEntry extends Object implements StructConverter
Represents a SOM `export_entry` structure

See Also:
  - The 32-bit PA-RISC Run-time Architecture Document

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final int`
  `SIZE`
  The size in bytes of a `SomExportEntry`

  ### Fields inherited from interface ghidra.app.util.bin.StructConverter

  `ASCII, BYTE, DWORD, IBO32, IBO64, POINTER, QWORD, SLEB128, STRING, ULEB128, UTF16, UTF8, VOID, WORD`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `SomExportEntry(BinaryReader reader, long stringTableLoc)`
  Creates a new `SomExportEntry`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getInfo()`
  Returns the size of the storage request if exported symbol is of type `STORAGE`, or the version of the exported symbol along with argument relocation information.
  `short`
  `getModuleIndex()`
  Returns the index into the module table of the module defining this symbol.
  `String`
  `getName()`
  Returns the symbol name.
  `int`
  `getNext()`
  Returns the next export record in the hash chain.
  `int`
  `getReserved1()`
  Returns the first reserved value.
  `int`
  `getType()`
  Returns the symbol type.
  `int`
  `getValue()`
  Returns the symbol address (subject to relocation).
  `boolean`
  `isTpRelative()`
  Returns whether or not this is a TLS export.
  `DataType`
  `toDataType()`
  Returns a structure datatype representing the contents of the implementor of this interface.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### SIZE

    public static final int SIZE
    The size in bytes of a `SomExportEntry`
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### SomExportEntry

    public SomExportEntry(BinaryReader reader, long stringTableLoc) throws IOException
    Creates a new `SomExportEntry`
    Parameters:
      `reader` - A `BinaryReader` positioned at the start of the export list
      `stringTableLoc` - The location of the string table
    Throws:
      `IOException` - if there was an IO-related error

- ## Method Details

  - ### getNext

    public int getNext()
    Returns the next export record in the hash chain.
    Returns:
      the next export record in the hash chain

  - ### getName

    public String getName()
    Returns the symbol name.
    Returns:
      the symbol name

  - ### getValue

    public int getValue()
    Returns the symbol address (subject to relocation).
    Returns:
      the symbol address (subject to relocation)

  - ### getInfo

    public int getInfo()
    Returns the size of the storage request if exported symbol is of type `STORAGE`, or the version of the exported symbol along with argument relocation information.
    Returns:
      the size of the storage request if exported symbol is of type `STORAGE`, or the version of the exported symbol along with argument relocation information

  - ### getType

    public int getType()
    Returns the symbol type.
    Returns:
      the symbol type
    See Also:
      - `SomConstants`

  - ### isTpRelative

    public boolean isTpRelative()
    Returns whether or not this is a TLS export.
    Returns:
      whether or not this is a TLS export

  - ### getReserved1

    public int getReserved1()
    Returns the first reserved value.
    Returns:
      the first reserved value

  - ### getModuleIndex

    public short getModuleIndex()
    Returns the index into the module table of the module defining this symbol.
    Returns:
      the index into the module table of the module defining this symbol

  - ### toDataType

    public DataType toDataType() throws DuplicateNameException, IOException
    Description copied from interface: `StructConverter`
    Returns a structure datatype representing the contents of the implementor of this interface.

    For example, given:

         class A {
             int foo;
             double bar;
         }

    The return value should be a structure data type with two data type components; an INT and a DOUBLE. The structure should contain field names and, if possible, field comments.

    Specified by:
      `toDataType` in interface `StructConverter`
    Returns:
      returns a structure datatype representing the implementor of this interface
    Throws:
      `DuplicateNameException` - when a datatype of the same name already exists
      `IOException` - if an IO-related error occurs
    See Also:
      - `StructureDataType`