Record Class ActionName
- Record Components:
name- the name of the action (given as the action attribute on method annotations)show- when to show the general UI action for this debugger actionenabler- determines when the action is enabled, based on the objectdisplay- the default text to displayicon- the default icon for menus and dialogsokText- the default text for confirm buttons in dialogs
Many common commands/actions have varying names across different back-end debuggers. We'd like to present common idioms for these common actions, but allow them to keep the names used by the back-end, because those names are probably better known to users of that back-end than Ghidra's action names are known. The action hints will affect the icon and placement of the action in the UI, but the display name will still reflect the name given by the back-end. Note that the "stock" action names are not a fixed enumeration. These are just the ones that might get special treatment from Ghidra. All methods should appear somewhere (at least, e.g., in context menus for applicable objects), even if the action name is unspecified or does not match a stock name. This list may change over time, but that shouldn't matter much. Each back-end should make its best effort to match its methods to these stock actions where applicable, but ultimately, it is up to the UI to decide what is presented where.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enumSpecifies when an action should appear in the menus. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ActionNameActivate a given object and optionally a timestatic final ActionNameForms: (target:Attachable), (pid:INT), (spec:STRING)static final ActionNamestatic final ActionNamestatic final ActionNamestatic final ActionNamestatic final ActionNameForms: (addr:ADDRESS), R/W(rng:RANGE), (expr:STRING)static final ActionNamestatic final ActionNameConnect the back-end to a (usually remote) targetstatic final ActionNamestatic final ActionNamestatic final ActionNameExecute a CLI commandstatic final ActionNameA weaker form of activate.static final ActionNamestatic final ActionNamestatic final ActionNameForms: (command_line:STRING), (file:STRING,args:STRING), (file:STRING,args:STRING_ARRAY), (ANY*)static final ActionNameForms: (rng:RANGE)static final ActionNamestatic final ActionNamestatic final ActionNameStep back is not typically available, except in emulators and timeless (or time-travel) debuggers.static final ActionNameThe action for steps that don't fit one of the common stepping actions.static final ActionNameAll of these will show in the "step" portion of the control toolbar, if present.static final ActionNamestatic final ActionNamestatic final ActionNameSkip is not typically available, except in emulators.static final ActionNamestatic final ActionNameForms: (addr:ADDRESS,data:BYTES)static final ActionNameForms: (frame:Frame,name:STRING,value:BYTES), (register:Register,value:BYTES) -
Constructor Summary
ConstructorsConstructorDescriptionActionName(String name, ActionName.Show show, ActionName.Enabler enabler, String display, Icon icon, String okText) Creates an instance of aActionNamerecord class. -
Method Summary
Modifier and TypeMethodDescriptiondisplay()Returns the value of thedisplayrecord component.enabler()Returns the value of theenablerrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.icon()Returns the value of theiconrecord component.name()Returns the value of thenamerecord component.static ActionNameokText()Returns the value of theokTextrecord component.show()Returns the value of theshowrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
REFRESH
-
ACTIVATE
Activate a given object and optionally a timeForms: (focus:Object), (focus:Object, snap:LONG), (focus:Object, time:STR)
-
FOCUS
A weaker form of activate.The user has expressed interest in an object, but has not activated it yet. This is often used to communicate selection (i.e., highlight) of the object. Whereas, double-clicking or pressing enter would more likely invoke 'activate.'
-
TOGGLE
-
DELETE
-
EXECUTE
Execute a CLI commandForms: (cmd:STRING):STRING; Optional arguments: capture:BOOL
-
CONNECT
Connect the back-end to a (usually remote) targetForms: (spec:STRING)
-
ATTACH
Forms: (target:Attachable), (pid:INT), (spec:STRING) -
DETACH
-
LAUNCH
Forms: (command_line:STRING), (file:STRING,args:STRING), (file:STRING,args:STRING_ARRAY), (ANY*) -
KILL
-
RESUME
-
INTERRUPT
-
STEP_INTO
All of these will show in the "step" portion of the control toolbar, if present. The difference in each "step_x" is minor. The icon will indicate which form, and the positions will be shifted so they appear in a consistent order. The display name is determined by the method name, not the action name. For stepping actions that don't fit the standards, useSTEP_EXT. There should be at most one of each standard applicable for any given context. (Multiple will appear, but may confuse the user.) You can have as many extended step actions as you like. They will be ordered lexicographically by name. -
STEP_OVER
-
STEP_OUT
-
STEP_SKIP
Skip is not typically available, except in emulators. If the back-end debugger does not have a command for this action out-of-the-box, we do not recommend trying to implement it yourself. The purpose of these actions just to expose/map each command to the UI, not to invent new features for the back-end debugger. -
STEP_BACK
Step back is not typically available, except in emulators and timeless (or time-travel) debuggers. -
STEP_EXT
The action for steps that don't fit one of the common stepping actions. -
BREAK_SW_EXECUTE
Forms: (addr:ADDRESS), R/W(rng:RANGE), (expr:STRING)Optional arguments: condition:STRING, commands:STRING
The client may pass either null or "" for condition and/or commands to indicate omissions of those arguments.
-
BREAK_HW_EXECUTE
-
BREAK_READ
-
BREAK_WRITE
-
BREAK_ACCESS
-
BREAK_EXT
-
READ_MEM
Forms: (rng:RANGE) -
WRITE_MEM
Forms: (addr:ADDRESS,data:BYTES) -
WRITE_REG
Forms: (frame:Frame,name:STRING,value:BYTES), (register:Register,value:BYTES)
-
-
Constructor Details
-
ActionName
public ActionName(String name, ActionName.Show show, ActionName.Enabler enabler, String display, Icon icon, String okText) Creates an instance of aActionNamerecord class.- Parameters:
name- the value for thenamerecord componentshow- the value for theshowrecord componentenabler- the value for theenablerrecord componentdisplay- the value for thedisplayrecord componenticon- the value for theiconrecord componentokText- the value for theokTextrecord component
-
-
Method Details
-
name
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
show
Returns the value of theshowrecord component.- Returns:
- the value of the
showrecord component
-
enabler
Returns the value of theenablerrecord component.- Returns:
- the value of the
enablerrecord component
-
display
Returns the value of thedisplayrecord component.- Returns:
- the value of the
displayrecord component
-
icon
Returns the value of theiconrecord component.- Returns:
- the value of the
iconrecord component
-
okText
Returns the value of theokTextrecord component.- Returns:
- the value of the
okTextrecord component
-