$ python
>>> import spiroclient
>>> c = spiroclient.SpiroClient("fred")
>>> c.dir()
()
>>> c.do("import java")
>>> c.dir()
('java',)
>>> c.java
<java package java at 22572221>
>>> java_sqrt = c.java.lang.Math.sqrt
>>> java_sqrt
<java function sqrt at 24918414>
>>> java_sqrt(16)
4.0
>>>
Or more simply:
$ python
>>> import spiroclient
>>> c = spiroclient.SpiroClient("fred")
>>> c.dir()
()
>>> java = c.doimport("java")
>>> java
<java package java at 22572221>
>>> sqrt = java.lang.Math.sqrt
>>> sqrt
<java function sqrt at 24918414>
>>> sqrt(16)
4.0
>>>
Yes, as you can see, we have C-Python manipulating java objects!