use of io.automatiko.engine.workflow.compiler.xml.SemanticModules in project automatiko-engine by automatiko-io.
the class XmlBPMNProcessDumper method readProcess.
@Override
public Process readProcess(String processXml) {
SemanticModules semanticModules = new SemanticModules();
semanticModules.addSemanticModule(new BPMNSemanticModule());
semanticModules.addSemanticModule(new BPMNExtensionsSemanticModule());
semanticModules.addSemanticModule(new BPMNDISemanticModule());
XmlProcessReader xmlReader = new XmlProcessReader(semanticModules, Thread.currentThread().getContextClassLoader());
try {
List<Process> processes = xmlReader.read(new StringReader(processXml));
return processes.get(0);
} catch (Throwable t) {
t.printStackTrace();
return null;
}
}
Aggregations