Package ghidra.app.util.bin.format.pe
Class ImportByName
java.lang.Object
ghidra.app.util.bin.format.pe.ImportByName
- All Implemented Interfaces:
ByteArrayConverter
,StructConverter
A class to represent the
IMAGE_IMPORT_BY_NAME
data structure defined in winnt.h
.
typedef struct _IMAGE_IMPORT_BY_NAME { WORD Hint; BYTE Name[1]; };
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionshort
getHint()
getName()
Returns an ASCIIZ string with the name of the imported function.int
Returns the actual number of bytes consumed by this structure in memory.byte[]
toBytes
(DataConverter dc) Returns a byte array representing this implementor of this interface.Returns a structure datatype representing the contents of the implementor of this interface.
-
Field Details
-
NAME
- See Also:
-
-
Constructor Details
-
ImportByName
- Parameters:
hint
- the import hint (ordinal)name
- the name of the imported function.
-
-
Method Details
-
getHint
public short getHint()- Returns:
- the export ordinal for the imported function
-
getName
Returns an ASCIIZ string with the name of the imported function.- Returns:
- an ASCIIZ string with the name of the imported function
-
toDataType
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 interfaceStructConverter
- Returns:
- returns a structure datatype representing the implementor of this interface
- Throws:
DuplicateNameException
- when a datatype of the same name already exists- See Also:
-
toBytes
Description copied from interface:ByteArrayConverter
Returns a byte array representing this implementor of this interface.- Specified by:
toBytes
in interfaceByteArrayConverter
- Parameters:
dc
- the data converter to use- Returns:
- a byte array representing this object
-
getSizeOf
public int getSizeOf()Returns the actual number of bytes consumed by this structure in memory.- Returns:
- the actual number of bytes consumed by this structure in memory
-