Package ghidra.program.util
Class SubDataFieldLocation
java.lang.Object
ghidra.program.util.ProgramLocation
ghidra.program.util.CodeUnitLocation
ghidra.program.util.SubDataFieldLocation
- All Implemented Interfaces:
Cloneable,Comparable<ProgramLocation>
The
SubDataFieldLocation class contains specific location information
within the Sub-data field of a CodeUnitLocation object.-
Field Summary
Fields inherited from class ghidra.program.util.ProgramLocation
addr, program, refAddr -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns a string representation of the dataValue at this location.Returns the name of the sub-data field.inthashCode()voidrestoreState(Program p, SaveState obj) Restore this program location using the given program and save state object.voidSave this program location to the given save state object.toString()Returns a String representation of this location.Methods inherited from class ghidra.program.util.CodeUnitLocation
isValidMethods inherited from class ghidra.program.util.ProgramLocation
clone, compareAddr, compareTo, getAddress, getByteAddress, getCharOffset, getColumn, getComponentPath, getLocation, getProgram, getRefAddress, getRow, getTranslatedCopy
-
Constructor Details
-
SubDataFieldLocation
public SubDataFieldLocation(Program program, Address addr, GroupPath path, int[] componentPath, Address refAddr, String rep, int charOffset, String fieldName) Construct a new SubDataFieldLocation object.- Parameters:
program- the program of the locationaddr- address of the locationpath- path associated with the address (an address could appear at more than one group path); may be nullcomponentPath- array of indexes for each nested data component; the index is the data component's index within its parent; may be nullrefAddr- the "referred to" address if the location is over a reference; may be nullrep- the String representation of the operand.charOffset- the character position within the operand string.fieldName- the name of the sub-data field
-
SubDataFieldLocation
public SubDataFieldLocation()Should only be used by XML restoration.
-
-
Method Details
-
getDataRepresentation
Returns a string representation of the dataValue at this location. -
getFieldName
Returns the name of the sub-data field. -
toString
Returns a String representation of this location.- Overrides:
toStringin classProgramLocation
-
hashCode
public int hashCode()- Overrides:
hashCodein classProgramLocation
-
equals
- Overrides:
equalsin classProgramLocation
-
restoreState
Description copied from class:ProgramLocationRestore this program location using the given program and save state object.- Overrides:
restoreStatein classProgramLocation- Parameters:
p- program to restore fromobj- the save state to restore from
-
saveState
Description copied from class:ProgramLocationSave this program location to the given save state object.- Overrides:
saveStatein classProgramLocation- Parameters:
obj- the save state object for saving the location
-