Class CmmnStartPlanItemInstanceBot
java.lang.Object
com.flowable.platform.service.bot.CmmnStartPlanItemInstanceBot
- All Implemented Interfaces:
BotService
public class CmmnStartPlanItemInstanceBot extends java.lang.Object implements BotService
A bot that handles actions originating from CMMN manual activates plan item instances.
When the action instance is invoked, the bot will call
CmmnRuntimeService.startPlanItemInstance(String).-
Field Summary
Fields Modifier and Type Field Description protected org.flowable.cmmn.engine.CmmnEngineConfigurationcmmnEngineConfigurationprotected org.flowable.cmmn.api.CmmnRepositoryServicecmmnRepositoryServiceprotected org.flowable.cmmn.api.CmmnRuntimeServicecmmnRuntimeServiceprotected org.flowable.form.api.FormRepositoryServiceformRepositoryServiceprotected org.flowable.form.api.FormServiceformService -
Constructor Summary
Constructors Constructor Description CmmnStartPlanItemInstanceBot(org.flowable.cmmn.api.CmmnRuntimeService cmmnRuntimeService, org.flowable.cmmn.api.CmmnRepositoryService cmmnRepositoryService, org.flowable.form.api.FormRepositoryService formRepositoryService, org.flowable.form.api.FormService formService, org.flowable.cmmn.engine.CmmnEngineConfiguration cmmnEngineConfiguration) -
Method Summary
Modifier and Type Method Description java.lang.StringgetDescription()Returns the optional description of this bot, describing its capabilities or prerequisites.java.lang.StringgetKey()Returns the key of this bot which is used to linkActionDefinitions to this bot.java.lang.StringgetName()Returns the name of this bot, typically used as the label for it.BotActionResultinvokeBot(HistoricActionInstance actionInstance, ActionDefinition actionDefinition, java.util.Map<java.lang.String,java.lang.Object> payload)Whenever an action definition is triggered, an action instance is created and this method is invoked in order to execute the action.
-
Field Details
-
cmmnRuntimeService
protected org.flowable.cmmn.api.CmmnRuntimeService cmmnRuntimeService -
cmmnRepositoryService
protected org.flowable.cmmn.api.CmmnRepositoryService cmmnRepositoryService -
formRepositoryService
protected org.flowable.form.api.FormRepositoryService formRepositoryService -
formService
protected org.flowable.form.api.FormService formService -
cmmnEngineConfiguration
protected org.flowable.cmmn.engine.CmmnEngineConfiguration cmmnEngineConfiguration
-
-
Constructor Details
-
CmmnStartPlanItemInstanceBot
public CmmnStartPlanItemInstanceBot(org.flowable.cmmn.api.CmmnRuntimeService cmmnRuntimeService, org.flowable.cmmn.api.CmmnRepositoryService cmmnRepositoryService, org.flowable.form.api.FormRepositoryService formRepositoryService, org.flowable.form.api.FormService formService, org.flowable.cmmn.engine.CmmnEngineConfiguration cmmnEngineConfiguration)
-
-
Method Details
-
getKey
public java.lang.String getKey()Description copied from interface:BotServiceReturns the key of this bot which is used to linkActionDefinitions to this bot.- Specified by:
getKeyin interfaceBotService- Returns:
- the key of this bot, which needs to be unique amongst other bots
-
getName
public java.lang.String getName()Description copied from interface:BotServiceReturns the name of this bot, typically used as the label for it.- Specified by:
getNamein interfaceBotService- Returns:
- the name of this bot
-
getDescription
public java.lang.String getDescription()Description copied from interface:BotServiceReturns the optional description of this bot, describing its capabilities or prerequisites.- Specified by:
getDescriptionin interfaceBotService- Returns:
- the optional description of this bot
-
invokeBot
public BotActionResult invokeBot(HistoricActionInstance actionInstance, ActionDefinition actionDefinition, java.util.Map<java.lang.String,java.lang.Object> payload)Description copied from interface:BotServiceWhenever an action definition is triggered, an action instance is created and this method is invoked in order to execute the action. You need to provide an action result according the execution and follow up needed.- Specified by:
invokeBotin interfaceBotService- Parameters:
actionInstance- the action instance to runactionDefinition- the action definition where the action instance is based onpayload- the optional payload containing the necessary information to run the action- Returns:
- the result of invoking the action
-