Here is my problem. I’m working on a Jython program and I have to extract numbers from a PyJavaInstance:
[{string1=”foo”, xxx1, xxx2, …, xxxN, string2=”bar”}]
(where xxx are the floating point numbers).
My question is how can I extract the numbers and put them in a more simple structure like a python list.
Thank you in advance.
A
PyJavaInstanceis a Jython wrapper around a Java instance; how you extract numbers from it depends on what it is. If you need to get a bunch of stuff – some of which are strings and some of which are floats, then: