use of org.kie.pmml.evaluator.core.utils.PMMLRequestDataBuilder in project drools by kiegroup.
the class PMMLTreeModelEvaluatorTest method getPMMLRequestData.
private PMMLRequestData getPMMLRequestData(String modelName, Map<String, Object> parameters) {
String correlationId = "CORRELATION_ID";
PMMLRequestDataBuilder pmmlRequestDataBuilder = new PMMLRequestDataBuilder(correlationId, modelName);
for (Map.Entry<String, Object> entry : parameters.entrySet()) {
Object pValue = entry.getValue();
Class class1 = pValue.getClass();
pmmlRequestDataBuilder.addParameter(entry.getKey(), pValue, class1);
}
return pmmlRequestDataBuilder.build();
}
use of org.kie.pmml.evaluator.core.utils.PMMLRequestDataBuilder in project drools by kiegroup.
the class PMMLScorecardModelEvaluatorTest method getPMMLRequestData.
private PMMLRequestData getPMMLRequestData(String modelName, Map<String, Object> parameters) {
String correlationId = "CORRELATION_ID";
PMMLRequestDataBuilder pmmlRequestDataBuilder = new PMMLRequestDataBuilder(correlationId, modelName);
for (Map.Entry<String, Object> entry : parameters.entrySet()) {
Object pValue = entry.getValue();
Class class1 = pValue.getClass();
pmmlRequestDataBuilder.addParameter(entry.getKey(), pValue, class1);
}
return pmmlRequestDataBuilder.build();
}
use of org.kie.pmml.evaluator.core.utils.PMMLRequestDataBuilder in project drools by kiegroup.
the class AbstractPMMLTest method getPMMLRequestData.
protected static PMMLRequestData getPMMLRequestData(String modelName, Map<String, Object> parameters) {
String correlationId = "CORRELATION_ID";
PMMLRequestDataBuilder pmmlRequestDataBuilder = new PMMLRequestDataBuilder(correlationId, modelName);
for (Map.Entry<String, Object> entry : parameters.entrySet()) {
Object pValue = entry.getValue();
Class class1 = pValue.getClass();
pmmlRequestDataBuilder.addParameter(entry.getKey(), pValue, class1);
}
return pmmlRequestDataBuilder.build();
}
use of org.kie.pmml.evaluator.core.utils.PMMLRequestDataBuilder in project drools by kiegroup.
the class DMNKiePMMLTrustyInvocationEvaluator method getPMMLPMMLContext.
private PMMLContext getPMMLPMMLContext(String correlationId, String modelName, DMNResult dmnr) {
PMMLRequestDataBuilder pmmlRequestDataBuilder = new PMMLRequestDataBuilder(correlationId, modelName);
for (FormalParameter p : parameters) {
Object pValue = getValueForPMMLInput(dmnr, p.name);
Class class1 = pValue.getClass();
pmmlRequestDataBuilder.addParameter(p.name, pValue, class1);
}
return new PMMLContextImpl(pmmlRequestDataBuilder.build());
}
Aggregations