public class DMNScenarioRunnerHelper extends AbstractRunnerHelper
| Constructor and Description |
|---|
DMNScenarioRunnerHelper() |
| Modifier and Type | Method and Description |
|---|---|
protected DMNScenarioExecutableBuilder |
createBuilderWrapper(org.kie.api.runtime.KieContainer kieContainer) |
protected Object |
createObject(ValueWrapper<Object> initialInstance,
String className,
Map<List<String>,Object> params,
ClassLoader classLoader)
Create and fill object with params.
|
protected Map<String,Object> |
defineInputValues(List<InstanceGiven> backgroundData,
List<InstanceGiven> givenData)
It returns a
Map which contains the actual data in the DMN Executable Builder (BC) or DMN Context (Kogito)
Typically, the Map contains a pair with the Fact Name as a Key and its Object as value
(another Map containing the fact properties)
(eg. |
protected Map<String,Object> |
executeScenario(org.kie.api.runtime.KieContainer kieContainer,
ScenarioRunnerData scenarioRunnerData,
ExpressionEvaluatorFactory expressionEvaluatorFactory,
ScesimModelDescriptor scesimModelDescriptor,
Settings settings) |
protected ScenarioResultMetadata |
extractResultMetadata(Map<String,Object> requestContext,
ScenarioWithIndex scenarioWithIndex) |
protected ValueWrapper |
getSingleFactValueResult(FactMapping factMapping,
FactMappingValue expectedResult,
org.kie.dmn.api.core.DMNDecisionResult decisionResult,
List<org.kie.dmn.api.core.DMNMessage> failureMessages,
ExpressionEvaluator expressionEvaluator) |
protected void |
verifyConditions(ScesimModelDescriptor scesimModelDescriptor,
ScenarioRunnerData scenarioRunnerData,
ExpressionEvaluatorFactory expressionEvaluatorFactory,
Map<String,Object> requestContext) |
extractBackgroundValues, extractExpectedValues, extractGivenValues, fillResult, getDirectMapping, getParamsForBean, getResultWrapper, groupByFactIdentifierAndFilter, isFactMappingValueToSkip, run, validateAssertionprotected Map<String,Object> executeScenario(org.kie.api.runtime.KieContainer kieContainer, ScenarioRunnerData scenarioRunnerData, ExpressionEvaluatorFactory expressionEvaluatorFactory, ScesimModelDescriptor scesimModelDescriptor, Settings settings)
executeScenario in class AbstractRunnerHelperprotected Map<String,Object> defineInputValues(List<InstanceGiven> backgroundData, List<InstanceGiven> givenData)
Map which contains the actual data in the DMN Executable Builder (BC) or DMN Context (Kogito)
Typically, the Map contains a pair with the Fact Name as a Key and its Object as value
(another Map containing the fact properties)
(eg. "Driver": {
"Name": "string"
}
)
In case of a Imported Fact, i.e. a Decision or a Input node imported from an external DMN file, the Map contains
the Fact prefix as a Key, which is the name of the imported DMN document, and another Map as value which
contains all the Imported Fact with that prefix.
(eg. "imp" : {
"Violation": {
"Code": "string"
}
}
)
If the the same fact is present in both Background and Given list, the Given one will override the background one.backgroundData, - givenData - protected ScenarioResultMetadata extractResultMetadata(Map<String,Object> requestContext, ScenarioWithIndex scenarioWithIndex)
extractResultMetadata in class AbstractRunnerHelperprotected void verifyConditions(ScesimModelDescriptor scesimModelDescriptor, ScenarioRunnerData scenarioRunnerData, ExpressionEvaluatorFactory expressionEvaluatorFactory, Map<String,Object> requestContext)
verifyConditions in class AbstractRunnerHelperprotected ValueWrapper getSingleFactValueResult(FactMapping factMapping, FactMappingValue expectedResult, org.kie.dmn.api.core.DMNDecisionResult decisionResult, List<org.kie.dmn.api.core.DMNMessage> failureMessages, ExpressionEvaluator expressionEvaluator)
protected Object createObject(ValueWrapper<Object> initialInstance, String className, Map<List<String>,Object> params, ClassLoader classLoader)
AbstractRunnerHelpercreateObject in class AbstractRunnerHelperprotected DMNScenarioExecutableBuilder createBuilderWrapper(org.kie.api.runtime.KieContainer kieContainer)
Copyright © 2001–2021 JBoss by Red Hat. All rights reserved.