Package ghidra.program.model.symbol
Class ThunkReference
java.lang.Object
ghidra.program.model.symbol.ThunkReference
- All Implemented Interfaces:
DynamicReference,Reference,Comparable<Reference>
Implementation for a Thunk Function reference.
These references are dynamic in nature and may not be explicitly added,
removed or altered. There presence is inferred by the existence
of a thunk function.
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionThunkReference(Address thunkAddr, Address thunkedAddr) Thunk reference constructor -
Method Summary
Modifier and TypeMethodDescriptionintbooleanGet the address of the codeunit that is making the reference.intGet the operand index of where this reference was placed.Get the type of reference being made.Gets the source of this reference.longGet the symbol ID associated with this reference.Get the "to" address for this reference.booleanReturns true if this reference is an instance of EntryReference.booleanReturns true if this reference is an instance of ExternalReference.booleanReturns true if this reference to an address in the programs memory space.booleanReturn true if this reference is on the Mnemonic and not on an operandbooleanReturns true if this reference is an instance of OffsetReference.booleanReturn true if this reference is on an operand and not on the Mnemonic.booleanReturn whether this reference is marked as primary.booleanReturns true if this reference to an address in the programs register space.booleanReturns true if this reference is an instance of ShiftedReference.booleanReturns true if this reference is an instance of StackReference and refers to a stack location.
-
Constructor Details
-
ThunkReference
Thunk reference constructor- Parameters:
thunkAddr- thunk function addressthunkedAddr- "thunked" function address
-
-
Method Details
-
getFromAddress
Description copied from interface:ReferenceGet the address of the codeunit that is making the reference.- Specified by:
getFromAddressin interfaceReference- See Also:
-
getToAddress
Description copied from interface:ReferenceGet the "to" address for this reference.- Specified by:
getToAddressin interfaceReference- See Also:
-
isPrimary
public boolean isPrimary()Description copied from interface:ReferenceReturn whether this reference is marked as primary. -
getSymbolID
public long getSymbolID()Description copied from interface:ReferenceGet the symbol ID associated with this reference. Applies to memory references only.- Specified by:
getSymbolIDin interfaceReference- Returns:
- symbol ID or -1 if no symbol is associated with this reference
- See Also:
-
getReferenceType
Description copied from interface:ReferenceGet the type of reference being made.- Specified by:
getReferenceTypein interfaceReference- See Also:
-
getOperandIndex
public int getOperandIndex()Description copied from interface:ReferenceGet the operand index of where this reference was placed.- Specified by:
getOperandIndexin interfaceReference- Returns:
- op index or ReferenceManager.MNEMONIC
- See Also:
-
isMnemonicReference
public boolean isMnemonicReference()Description copied from interface:ReferenceReturn true if this reference is on the Mnemonic and not on an operand- Specified by:
isMnemonicReferencein interfaceReference- See Also:
-
isOperandReference
public boolean isOperandReference()Description copied from interface:ReferenceReturn true if this reference is on an operand and not on the Mnemonic.- Specified by:
isOperandReferencein interfaceReference- See Also:
-
compareTo
- Specified by:
compareToin interfaceComparable<Reference>- See Also:
-
equals
-
isExternalReference
public boolean isExternalReference()Description copied from interface:ReferenceReturns true if this reference is an instance of ExternalReference.- Specified by:
isExternalReferencein interfaceReference- See Also:
-
isOffsetReference
public boolean isOffsetReference()Description copied from interface:ReferenceReturns true if this reference is an instance of OffsetReference.- Specified by:
isOffsetReferencein interfaceReference- See Also:
-
isShiftedReference
public boolean isShiftedReference()Description copied from interface:ReferenceReturns true if this reference is an instance of ShiftedReference.- Specified by:
isShiftedReferencein interfaceReference- See Also:
-
isEntryPointReference
public boolean isEntryPointReference()Description copied from interface:ReferenceReturns true if this reference is an instance of EntryReference.- Specified by:
isEntryPointReferencein interfaceReference- See Also:
-
isMemoryReference
public boolean isMemoryReference()Description copied from interface:ReferenceReturns true if this reference to an address in the programs memory space. This includes offset and shifted references.- Specified by:
isMemoryReferencein interfaceReference- See Also:
-
isRegisterReference
public boolean isRegisterReference()Description copied from interface:ReferenceReturns true if this reference to an address in the programs register space.- Specified by:
isRegisterReferencein interfaceReference- See Also:
-
isStackReference
public boolean isStackReference()Description copied from interface:ReferenceReturns true if this reference is an instance of StackReference and refers to a stack location.- Specified by:
isStackReferencein interfaceReference- See Also:
-
getSource
Description copied from interface:ReferenceGets the source of this reference.SourceTypes
-