byte[] bytes = (byte[]) bytesObject;
ResourceSet resourceSet = getResourceSet();
String fixflowFilePath = ProcessEngineManagement.getDefaultProcessEngine().getProcessEngineConfiguration().getNoneTemplateFilePath();
URL url = ReflectUtil.getResource(fixflowFilePath);
if(url == null){
throw new FixFlowClassLoadingException(ExceptionCode.CLASSLOAD_EXCEPTION_FILENOTFOUND,fixflowFilePath);
}
String filePath = url.toString();
Resource ddddResource = null;
try {
if (!filePath.startsWith("jar")) {
filePath = java.net.URLDecoder.decode(url.getFile(),"utf-8");
ddddResource = resourceSet.createResource(URI.createFileURI(filePath));
} else {
ddddResource = resourceSet.createResource(URI.createURI(filePath));
}
ddddResource.load(new ByteArrayInputStream(bytes), null);
} catch (Exception e) {
throw new FixFlowClassLoadingException(ExceptionCode.CLASSLOAD_EXCEPTION, e);
}
DefinitionsBehavior definitions = (DefinitionsBehavior) ddddResource.getContents().get(0).eContents().get(0);
definitions.setProcessId(processId);
for (RootElement rootElement : definitions.getRootElements()) {