Using JPE and Jython together?

Hamish Lawson hamish_lawson at yahoo.co.uk
Thu Feb 21 14:02:59 EST 2002


Jython provides Python implemented for the Java Virtual Machine, and
as such can't directly make use of Python extensions written in C. JPE
(Java-Python Extension) on the other hand provides a bridging
mechanism between Java and the native Python interpreter (including
Python C extensions). Though I haven't used JPE at all and Jython only
a little, I'm wondering whether it might be possible to use JPE from
within Jython to give access to Python C extensions (I'm presuming
that whatever mechanism JPE provides for Java to call across to the
native Python interpreter could be used by any language that compiles
to Java bytecode - including Jython). If so, then the next step could
be to hide the explicit invocation of the JPE mechanism from within
Jython and instead hook into the import mechanism to allow direct
importing of Python C extensions. Might such integration be a feasible
development route for Jython?

Hamish Lawson



More information about the Python-list mailing list