On Tue, 29 Jun 2021 at 15:49, Christian Grün christian.gruen@gmail.com wrote:
Hi Reece,
I implemented an initial version of convert:from-java [1, 2].
Great, thanks.
Looking forward to your feedback and further suggestions,
Trying to use convert:from-java on a list of a custom Java object, I get:
[convert:java] Java object cannot be converted: "Word(text=test, normalized=test)".
It should just marshal the Java object like is done with the Java interop in this case.
My initial testing on other cases (set-to-sequence) indicate that it is slightly faster than the XQuery code I had -- I haven't measured them in isolation, just on a test example I have.
Kind regards, Reece
Christian
[1] https://github.com/BaseXdb/basex/issues/2017 [2] https://files.basex.org/releases/latest/
On Tue, Jun 29, 2021 at 1:56 PM Reece Dunn msclrhd@googlemail.com wrote:
On Tue, 29 Jun 2021 at 12:31, Christian Grün christian.gruen@gmail.com
wrote:
Out of interest, and as you seem to have worked with both the Saxon and BaseX Java mapping: Did you encounter other mapping details that you believe are handled better in one of the processors?
I've not actually used Saxon's Java bindings, so I can't go into more
details other than what the documentation says. This is currently the only project I'm using Java bindings for.
I'm only aware of the Saxon logic as I plan at some point to have Java
integration in my XQuery plugin so you can navigate to the Java class/method/etc., have it auto-complete methods, and perform some static analysis like checking the number of arguments.
Kind regards, Reece