Solved: from a private discussion with Jim: use the latest version 3.0 beta2 and...
I like to do something like that: function calledFromJava(factory) -- works: local...