Package ghidra.program.model.symbol
Interface OffsetReference
- All Superinterfaces:
Comparable<Reference>
,Reference
OffsetReference
is a memory reference whose "to" address is
computed from a base address plus an offset.
NOTE: References into the reserved EXTERNAL block must report getToAddress()
the same as getBaseAddress()
regardless of offset value due to symbol
spacing limitations within the EXTERNAL block. See MemoryBlock.EXTERNAL_BLOCK_NAME
.
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns the base address.long
Returns the offset.Return the base address plus the offset.Methods inherited from interface java.lang.Comparable
compareTo
Methods inherited from interface ghidra.program.model.symbol.Reference
getFromAddress, getOperandIndex, getReferenceType, getSource, getSymbolID, isEntryPointReference, isExternalReference, isMemoryReference, isMnemonicReference, isOffsetReference, isOperandReference, isPrimary, isRegisterReference, isShiftedReference, isStackReference
-
Method Details
-
getOffset
long getOffset()Returns the offset.- Returns:
- the offset
-
getBaseAddress
Address getBaseAddress()Returns the base address.- Returns:
- the address
-
getToAddress
Address getToAddress()Return the base address plus the offset. The exception to this is the EXTERNAL block case where this method returns the base address regardless of the offset value.- Specified by:
getToAddress
in interfaceReference
- Returns:
- reference "to" address
-