public class MockDataWorkItemHandler extends Object implements org.kie.api.runtime.process.WorkItemHandler
| Constructor and Description |
|---|
MockDataWorkItemHandler(Function<Map<String,Object>,Map<String,Object>> outputDataSupplier)
Create handler with custom function that will supply output data.
|
MockDataWorkItemHandler(Map<String,Object> outputData)
Create handler that will always complete work items with exact same map of data.
|
| Modifier and Type | Method and Description |
|---|---|
void |
abortWorkItem(org.kie.api.runtime.process.WorkItem workItem,
org.kie.api.runtime.process.WorkItemManager manager) |
void |
executeWorkItem(org.kie.api.runtime.process.WorkItem workItem,
org.kie.api.runtime.process.WorkItemManager manager) |
public MockDataWorkItemHandler(Map<String,Object> outputData)
outputData - data to be used when completing work itemspublic MockDataWorkItemHandler(Function<Map<String,Object>,Map<String,Object>> outputDataSupplier)
outputDataSupplier - function responsible to provide output datapublic void executeWorkItem(org.kie.api.runtime.process.WorkItem workItem,
org.kie.api.runtime.process.WorkItemManager manager)
executeWorkItem in interface org.kie.api.runtime.process.WorkItemHandlerpublic void abortWorkItem(org.kie.api.runtime.process.WorkItem workItem,
org.kie.api.runtime.process.WorkItemManager manager)
abortWorkItem in interface org.kie.api.runtime.process.WorkItemHandlerCopyright © 2001–2020 JBoss by Red Hat. All rights reserved.