com.dlsc.flexgantt.command.eventline

## Class DefaultDeleteEventlineObjectCommand

- java.lang.Object
- - com.dlsc.flexgantt.command.AbstractCommand
  - - com.dlsc.flexgantt.command.eventline.DefaultDeleteEventlineObjectCommand

- All Implemented Interfaces:
    ICommand, Serializable

      public class DefaultDeleteEventlineObjectCommand
      extends AbstractCommand

  A command that is used to delete an eventline object from the eventline model. This command can only be used in situations where the model is an instance of `DefaultEventlineModel` and the eventline object implements the `IEventlineObject` interface.
  Since:
    1.0
  Version:
    $Revision: 1.7 $
  Author:
    Dirk Lemmermann
  See Also:
    `DefaultEventlineModel.removeEventlineObject(IEventlineObject)`, `IEventlineObject`, `IEditEventlineObjectPolicy.getDeleteCommand(java.util.Collection, com.dlsc.flexgantt.model.eventline.IEventlineModel)`, Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DefaultDeleteEventlineObjectCommand(IEventlineObject object, DefaultEventlineModel model)` Constructs a new command.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `executeCommand(IProgressMonitor monitor)` Executes the command.
    `IEventlineObject` | `getEventlineObject()` Returns the eventline object that was / will be deleted
    `DefaultEventlineModel` | `getModel()` Returns the model of which the eventline object is a member.
    `void` | `undoCommand(IProgressMonitor monitor)` Undos the command.

    - ### Methods inherited from class com.dlsc.flexgantt.command.AbstractCommand

      `getName, isRedoable, isRelevant, isUndoable, redoCommand, setName`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### DefaultDeleteEventlineObjectCommand

          public DefaultDeleteEventlineObjectCommand(IEventlineObject object,
                                                     DefaultEventlineModel model)

      Constructs a new command.
      Parameters:
        `object` - the eventline object that will be deleted
        `model` - the model of which the object is a member
      Since:
        1.0

  - ### Method Detail

    - #### executeCommand

          public void executeCommand(IProgressMonitor monitor)
                              throws CommandException

      Description copied from interface: `ICommand`
      Executes the command.
      Parameters:
        `monitor` - a progress monitor
      Throws:
        `CommandException` - if anything during the execution of the command has gone wrong

    - #### undoCommand

          public void undoCommand(IProgressMonitor monitor)
                           throws CommandException

      Description copied from interface: `ICommand`
      Undos the command.
      Parameters:
        `monitor` - a progress monitor
      Throws:
        `CommandException` - if anything during the execution of the command has gone wrong

    - #### getEventlineObject

          public IEventlineObject getEventlineObject()

      Returns the eventline object that was / will be deleted
      Returns:
        the deleted eventline object
      Since:
        1.0

    - #### getModel

          public DefaultEventlineModel getModel()

      Returns the model of which the eventline object is a member.
      Returns:
        the data source to which the eventline object belongs
      Since:
        1.0

Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.