Package ghidra.program.model.pcode
Class JumpTable
java.lang.Object
ghidra.program.model.pcode.JumpTable
JumpTable found as part of the decompilation of a function
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
ChangeModifier and TypeMethodDescriptionvoidDecode a JumpTable object from the stream.voidAddress[]getCases()NEWstatic intgetFormatOverride(Function func, Address opAddress) Get any case format override for this jumptable.Integer[]booleanisEmpty()static JumpTablereadOverride(Namespace space, SymbolTable symtab) NEWstatic voidwriteFormat(Function func, Address opAddress, int displayFormat) Write/update the current display format for a JumpTable.voidwriteOverride(Function func)
-
Constructor Details
-
JumpTable
public JumpTable() -
JumpTable
-
-
Method Details
-
isEmpty
public boolean isEmpty() -
decode
Decode a JumpTable object from the stream.- Parameters:
decoder- is the stream decoder- Throws:
DecoderException- for invalid encodings
-
encode
- Throws:
IOException
-
getSwitchAddress
-
getCases
-
getLabelValues
-
getLoadTables
-
getFormatOverride NEW
Get any case format override for this jumptable.- Parameters:
func- is the function with the jumptableopAddress- is the address of the call point using the table- Returns:
- the overriding format if it exists or EquateSymbol.FORMAT_DEFAULT otherwise
-
writeFormat NEW
public static void writeFormat(Function func, Address opAddress, int displayFormat) throws InvalidInputException Write/update the current display format for a JumpTable. The format is stored as a symbol with a name like "format_dec" or "format_char" Any previous existing symbol is removed.- Parameters:
func- is the function containing the switchopAddress- is the address of the CALLINDdisplayFormat- is the new desired format- Throws:
InvalidInputException- for problems writing to the database
-
writeOverride
- Throws:
InvalidInputException
-
readOverride
-