[jboss-user] [jBPM] - Problems with usage python language in jpdl.xml
Andrey Chuyko
do-not-reply at jboss.com
Tue Mar 30 05:20:30 EDT 2010
Andrey Chuyko [http://community.jboss.org/people/chuiko.andrew] replied to the discussion
"Problems with usage python language in jpdl.xml"
To view the discussion, visit: http://community.jboss.org/message/534581#534581
--------------------------------------------------------------
Hi !
I had localized this problem. The class org.jbpm.pvm.internal.script.EnvironmentBindings doesn`t store locale variables from script:
+*public Object put(String key, Object value) {
return null;
}*+
Groovy engine ignores it and stores local variables in its own storage.
Jython engine obeys the limitations of Bindings, so it can`t store local variables if Bindings doesn`t allow it!!!!!
If is it desireable behaviour ?
Possible solution is adding local storage to EnvironmentBindings and to allow putting values in it.
Such as :
+*private HashMap<String, Object> locals = new HashMap<String, Object>();*+
+*
*+
+*+*public Object put(String key, Object value) {
return null;
}*+*+
+*
*+
+*public Object get(Object key) {*+
+* if (locals.containsKey((String)key))*+
+* return locals.+*get((String)key);*+*+
+* else return environment.get((String)key);}*+
What do you think about this?
Thanks a lot, Andrew
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/534581#534581]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20100330/d7df861b/attachment.html
More information about the jboss-user
mailing list