Re: java object as pertinent data.
Vojtech Huser <[email protected]> Thu, 8 Sep 2005 14:51:50 -0600
| Newsgroups | gmane.comp.java.enhydra.shark |
|---|---|
| Message-ID | <[email protected]> |
Geeta, I have the same problem as Elsa. I have read you reply and tried to use it but I get a lot of errors when I try to finish the code. (which you sugested) e.g. creating correctly the currentActivity object (as WfActivity object) in my TestUsingJavaClassAsParam01.java. Is there any complete examle where such UsingJavaClassAsParam.java would be in full. also the code for "metier.class" and the corresponding .xpdl file... where it is defined as a type.... ...rewriting all my objects into string variables and passing those is very tedious. (which is what I have to use since there are some examples for using those...) Vojtech On 8/30/05, [email protected] <[email protected]> wrote: > > > "Planterose Elsa" <[email protected]> wrote on 08/30/2005 11:16:29 > AM: > > > Hello, > > I am testing Shark an I try to use a java object as pertinent data. > > My problem, is that I didn't find how to do in Shak documentation. > > Hi Elsa, here's a link which explains how to define the data in the xpdl: > http://shark.objectweb.org/doc/1.1/HowTo/how_to.html#d0e360 > > Also, I am assuming you use JaWE to define your xpdl, correct? Then you > can look at the tutorial/Manual on Jawe - I am pretty sure I have seen a > section on this. > > > How must I define this data in my process xpdl? > > If my java class's name is "metier.class", where must I do put it > > Bascially you must have your class in Shark's classpath. > > > and how can I call it? > > You can do something like this in your code to access it: > > //first get the process context map: > Map processContextMap = currentActivity.process_context(); > (currentActivity is WfActivity object) > MyClass myClassObject = (MyClass) processContextMap.get > ("processVariableName"); > > //do something with myClassObject here..Then: > > //update: > processContextMap.put("processVariableName", myClassObject); > currentActivity.set_result(processContextMap); > > > Thank you for your help > > Elsa > > > > Regards, > Geeta > > > -- > You receive this message as a subscriber of the [email protected] list. > To unsubscribe: mailto:[email protected] > For general help: mailto:[email protected]?subject=help > ObjectWeb mailing lists service home page: http://www.objectweb.org/wws > > >
message-footer.txt
(text/plain, 271 B)
-- You receive this message as a subscriber of the [email protected] mailing list. To unsubscribe: mailto:[email protected] For general help: mailto:[email protected]?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws