Package ghidra.app.cmd.label
Class AddLabelCmd
java.lang.Object
ghidra.app.cmd.label.AddLabelCmd
Command to add a label.
-
Constructor Summary
ConstructorDescriptionAddLabelCmd
(Address addr, String name, boolean useLocalNamespace, SourceType source) Constructs a new command for adding a label.AddLabelCmd
(Address addr, String name, Namespace namespace, SourceType source) Constructs a new command for adding a label.AddLabelCmd
(Address addr, String name, SourceType source) Constructs a new command for adding a label. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Applies the command to the given domain object.getName()
Returns the name of this command.Returns the status message indicating the status of the command.void
setLabelAddr
(Address addr) void
setLabelName
(String name) void
setNamespace
(Namespace namespace)
-
Constructor Details
-
AddLabelCmd
Constructs a new command for adding a label.- Parameters:
addr
- address where the label is to be added.name
- name of the new label. A null name will cause a default label be added.namespace
- the namespace of the label. (i.e. the namespace this label is associated with)source
- the source of this symbol
-
AddLabelCmd
Constructs a new command for adding a label.- Parameters:
addr
- address where the label is to be added.name
- name of the new label. A null name will cause a default label be added.useLocalNamespace
- If true, the namespace will be that of the lowest level namespace for the indicated address. If false, the global namespace is used for the namespace.source
- the source of this symbol: Symbol.DEFAULT, Symbol.IMPORTED, Symbol.ANALYSIS, or Symbol.USER_DEFINED.
-
AddLabelCmd
Constructs a new command for adding a label.- Parameters:
addr
- address where the label is to be added.name
- name of the new label. A null name will cause a default label be added.source
- the source of this symbol
-
-
Method Details
-
applyTo
Description copied from interface:Command
Applies the command to the given domain object. -
getStatusMsg
Description copied from interface:Command
Returns the status message indicating the status of the command.- Specified by:
getStatusMsg
in interfaceCommand<Program>
- Returns:
- reason for failure, or null if the status of the command was successful
-
getName
Description copied from interface:Command
Returns the name of this command. -
getLabelName
-
getLabelAddr
-
setLabelAddr
-
setLabelName
-
setNamespace
-
getSymbol
-