Class CommandActionModel

All Implemented Interfaces:
IEditableModel, IModel, IValue<String>, IValidable, IModelApiAwareModel, IFormValue<String,FormCommand>, IHandlerModel<FormCommand>
Direct Known Subclasses:
CommandActionExtensionModel

public class CommandActionModel extends PojoValue<String> implements IHandlerModel<FormCommand>
The IHandlerModel implementation for form command.
  • Constructor Details

  • Method Details

    • getChange

      public IChange getChange()
      Specified by:
      getChange in interface IModel
      Overrides:
      getChange in class PojoValue<String>
      Returns:
      change describing the modifications done to the model.
    • getForm

      public Form getForm()
      Description copied from interface: IFormValue
      Gets form model.
      Specified by:
      getForm in interface IFormValue<String,FormCommand>
      Returns:
      the form model.
    • getSelection

      public FormCommand getSelection()
      Description copied from interface: IFormValue
      Return the selected object of form model.
      Specified by:
      getSelection in interface IFormValue<String,FormCommand>
      Returns:
      the selected object.
    • getModelApi

      public IModelApi getModelApi()
      Description copied from interface: IModelApiAwareModel
      Returns the model API.
      Specified by:
      getModelApi in interface IModelApiAwareModel
      Returns:
      the model API or null if it is not set.
    • setModelApi

      public void setModelApi(IModelApi modelApi)
      Description copied from interface: IModelApiAwareModel
      Sets the specified API to the model.
      Specified by:
      setModelApi in interface IModelApiAwareModel
      Parameters:
      modelApi - the API, can be null.
    • getHandlers

      public Collection<String> getHandlers()
      Description copied from interface: IHandlerModel
      Returns a collection of possible event handlers.
      Specified by:
      getHandlers in interface IHandlerModel<FormCommand>
      Returns:
      the collection of handlers for current event, never null
    • getEvent

      public Event getEvent()
      Description copied from interface: IHandlerModel
      Returns the form model object event for this handler.
      Specified by:
      getEvent in interface IHandlerModel<FormCommand>
      Returns:
      the Event, never null
    • processHandlerInBslModule

      public void processHandlerInBslModule()
      Description copied from interface: IHandlerModel
      Processes current method selection in the BSL module.
      Specified by:
      processHandlerInBslModule in interface IHandlerModel<FormCommand>
    • setCommandHandler

      protected void setCommandHandler(String handlerName, FormCommand command)
      Sets a form command handler with the provided handler name.
      Parameters:
      handlerName - a handler name, cannot be null
      command - a form command to set handler, cannot be null
    • clearCommandHandler

      protected void clearCommandHandler(FormCommand command)
      Clears a form command handler.
      Parameters:
      command - a form command to clear handler, cannot be null
    • executeCommand

      protected void executeCommand(String commandId, Map<String,String> commandParameters)
      Executes the provided command in the Eclipse command service with the provided command parameters.
      Parameters:
      commandId - the command identifier, cannot be null
      commandParameters - a map of command parameters, cannot be null