[jboss-svn-commits] JBL Code SVN: r24585 - labs/jbossrules/branches/mfossati/drools-process-enterprise/src/main/java/org/drools/persistence/processinstance.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Wed Jan 7 12:02:35 EST 2009
Author: mfossati
Date: 2009-01-07 12:02:35 -0500 (Wed, 07 Jan 2009)
New Revision: 24585
Modified:
labs/jbossrules/branches/mfossati/drools-process-enterprise/src/main/java/org/drools/persistence/processinstance/ProcessInstanceInfo.java
Log:
Test case + fixs. Process Working with persistence.
Modified: labs/jbossrules/branches/mfossati/drools-process-enterprise/src/main/java/org/drools/persistence/processinstance/ProcessInstanceInfo.java
===================================================================
--- labs/jbossrules/branches/mfossati/drools-process-enterprise/src/main/java/org/drools/persistence/processinstance/ProcessInstanceInfo.java 2009-01-07 17:01:51 UTC (rev 24584)
+++ labs/jbossrules/branches/mfossati/drools-process-enterprise/src/main/java/org/drools/persistence/processinstance/ProcessInstanceInfo.java 2009-01-07 17:02:35 UTC (rev 24585)
@@ -20,6 +20,7 @@
import org.drools.marshalling.MarshallerReaderContext;
import org.drools.marshalling.MarshallerWriteContext;
import org.drools.marshalling.OutputMarshaller;
+import org.drools.marshalling.ProcessMarshaller;
import org.drools.ruleflow.instance.RuleFlowProcessInstance;
import org.drools.runtime.process.ProcessInstance;
import org.hibernate.annotations.CollectionOfElements;
@@ -82,7 +83,8 @@
try {
ByteArrayInputStream bais = new ByteArrayInputStream(processInstanceByteArray);
MarshallerReaderContext context = new MarshallerReaderContext(bais, null, null, null);
- processInstance = InputMarshaller.readProcessInstance(context);
+ ProcessMarshaller marshaller = InputMarshaller.getMarshaller(context);
+ processInstance = marshaller.readProcessInstance(context);
context.close();
} catch (IOException e) {
e.printStackTrace();
@@ -98,7 +100,7 @@
ByteArrayOutputStream baos = new ByteArrayOutputStream();
try {
MarshallerWriteContext context = new MarshallerWriteContext(baos, null, null, null, null);
- OutputMarshaller.writeProcessInstance(context, (RuleFlowProcessInstance) processInstance);
+ OutputMarshaller.writeProcessInstance(context, processInstance);
context.close();
} catch (IOException e) {
throw new IllegalArgumentException(
More information about the jboss-svn-commits
mailing list