Class CommandActionModel
java.lang.Object
com._1c.g5.aef2.validators.Validable
com._1c.g5.aef2.models.Model
com._1c.g5.aef2.models.EditableModel
com._1c.g5.aef2.models.value.Value<T>
com._1c.g5.aef2.models.pojo.PojoValue<String>
com._1c.g5.v8.dt.form.ui.properties.models.CommandActionModel
- All Implemented Interfaces:
IEditableModel
,IModel
,IValue<String>
,IValidable
,IModelApiAwareModel
,IFormValue<String,
,FormCommand> IHandlerModel<FormCommand>
- Direct Known Subclasses:
CommandActionExtensionModel
The
IHandlerModel
implementation for form command.-
Constructor Summary
ConstructorsConstructorDescriptionCommandActionModel
(Form form, FormCommand command, IBslModuleContentManagementService bslModuleContentManagementService) Constructor.CommandActionModel
(Form form, FormCommand command, IBslModuleContentManagementService bslModuleContentManagementService, String handler) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
clearCommandHandler
(FormCommand command) Clears a form command handler.protected void
executeCommand
(String commandId, Map<String, String> commandParameters) Executes the provided command in the Eclipse command service with the provided command parameters.getEvent()
Returns the form model object event for this handler.getForm()
Gets form model.Returns a collection of possible event handlers.Returns the model API.Return the selected object of form model.void
Processes current method selection in the BSL module.protected void
setCommandHandler
(String handlerName, FormCommand command) Sets a form command handler with the provided handler name.void
setModelApi
(IModelApi modelApi) Sets the specified API to the model.Methods inherited from class com._1c.g5.aef2.models.value.Value
addValueListener, createWorkingCopy, discard, dispose, get, getCommittedValue, getUncommittedValue, getValidatorTarget, isEqual, notifyValueChanged, queueNotifyValueChanged, removeValueListener, set, setCommittedValue, setUncommittedValue, setValue, toString
Methods inherited from class com._1c.g5.aef2.models.EditableModel
isEditable, setEditable
Methods inherited from class com._1c.g5.aef2.models.Model
addModelListener, beginExternalUpdate, checkOffline, checkOnline, commit, endExternalUpdate, getComponent, getCurrentChangeOrigin, getRunnableQueue, isOnline, notifyModelChanged, notifyModelCommitted, removeModelListener, setComponent, setOnline
Methods inherited from class com._1c.g5.aef2.validators.Validable
addValidator, removeValidator, validate, validate
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com._1c.g5.aef2.models.IModel
addModelListener, commit, discard, dispose, getComponent, isOnline, removeModelListener, setComponent
Methods inherited from interface com._1c.g5.aef2.validators.IValidable
addValidator, removeValidator, validate, validate
Methods inherited from interface com._1c.g5.aef2.models.value.IValue
addValueListener, createWorkingCopy, get, isEqual, removeValueListener, set
-
Constructor Details
-
CommandActionModel
public CommandActionModel(Form form, FormCommand command, IBslModuleContentManagementService bslModuleContentManagementService) Constructor.- Parameters:
form
- the parent form, cannot benull
command
- the form command, cannot benull
bslModuleContentManagementService
- theIBslModuleContentManagementService
, cannot benull
-
CommandActionModel
public CommandActionModel(Form form, FormCommand command, IBslModuleContentManagementService bslModuleContentManagementService, String handler) Constructor.- Parameters:
form
- the parent form, cannot benull
command
- the form command, cannot benull
bslModuleContentManagementService
- theIBslModuleContentManagementService
. Can not benull
handler
- the command actual action handler ornull of none
-
-
Method Details
-
getChange
-
getForm
Description copied from interface:IFormValue
Gets form model.- Specified by:
getForm
in interfaceIFormValue<String,
FormCommand> - Returns:
- the form model.
-
getSelection
Description copied from interface:IFormValue
Return the selected object of form model.- Specified by:
getSelection
in interfaceIFormValue<String,
FormCommand> - Returns:
- the selected object.
-
getModelApi
Description copied from interface:IModelApiAwareModel
Returns the model API.- Specified by:
getModelApi
in interfaceIModelApiAwareModel
- Returns:
- the model API or
null
if it is not set.
-
setModelApi
Description copied from interface:IModelApiAwareModel
Sets the specified API to the model.- Specified by:
setModelApi
in interfaceIModelApiAwareModel
- Parameters:
modelApi
- the API, can benull
.
-
getHandlers
Description copied from interface:IHandlerModel
Returns a collection of possible event handlers.- Specified by:
getHandlers
in interfaceIHandlerModel<FormCommand>
- Returns:
- the collection of handlers for current
event
, nevernull
-
getEvent
Description copied from interface:IHandlerModel
Returns the form model object event for this handler.- Specified by:
getEvent
in interfaceIHandlerModel<FormCommand>
- Returns:
- the
Event
, nevernull
-
processHandlerInBslModule
public void processHandlerInBslModule()Description copied from interface:IHandlerModel
Processes current method selection in the BSL module.- Specified by:
processHandlerInBslModule
in interfaceIHandlerModel<FormCommand>
-
setCommandHandler
Sets a form command handler with the provided handler name.- Parameters:
handlerName
- a handler name, cannot benull
command
- a form command to set handler, cannot benull
-
clearCommandHandler
Clears a form command handler.- Parameters:
command
- a form command to clear handler, cannot benull
-
executeCommand
Executes the provided command in the Eclipse command service with the provided command parameters.- Parameters:
commandId
- the command identifier, cannot benull
commandParameters
- a map of command parameters, cannot benull
-