Class AbstractCreateStructureCmd

java.lang.Object
ghidra.app.cmd.data.AbstractCreateStructureCmd
All Implemented Interfaces:
Command
Direct Known Subclasses:
CreateStructureCmd, CreateStructureInStructureCmd

public abstract class AbstractCreateStructureCmd extends Object implements Command
A base class to hold duplicate information for commands that create structures. This class implements the logic of the applyTo(DomainObject) method so that child implementations need only to implement the abstract methods.
Since:
Tracker Id 383
  • Method Details

    • applyTo

      public boolean applyTo(DomainObject domainObject)
      Applies this command to the given domain object.

      This method is a Form Template method in that child subclasses do not need to override the method, but only need to implement the methods that this method calls.

      Specified by:
      applyTo in interface Command
      Parameters:
      domainObject - The domain object that is associated with this command
      Returns:
      true if the command applied successfully
      See Also:
    • getNewDataType

      public DataType getNewDataType()
      Get the new structure data type which was created.
      Returns:
      new structure.
    • getStatusMsg

      public String getStatusMsg()
      Description copied from interface: Command
      Returns the status message indicating the status of the command.
      Specified by:
      getStatusMsg in interface Command
      Returns:
      reason for failure, or null if the status of the command was successful
      See Also:
    • getName

      public String getName()
      Description copied from interface: Command
      Returns the name of this command.
      Specified by:
      getName in interface Command
      Returns:
      the name of this command
      See Also: