Fwd: Jython

1 view
Skip to first unread message

Duncan Child

unread,
May 8, 2009, 10:08:17 AM5/8/09
to ml...@conocophillips.com, geocra...@googlegroups.com
---------- Forwarded message ----------
From: Dan Dromereschi <dda...@gmail.com>
Date: Fri, May 8, 2009 at 7:59 AM
Subject: Jython
To: Duncan Child <duncan...@gmail.com>


Hi Duncan,


>> MIke don't do this. This couples IJython with proprietary modules which is bad ....

The easiest solution is to add a dependency from
org.geocraft.ui.ijython to the bundle containing the needed class to
import. That specific bundle probably needs to export the package that
contains the class to be imported into the Jython namespace.

This is probably not a nice solution anyway, so I guess another plan
should be applied here:


>> Mike - see if you can use this approach ....

org.geocraft.ui.ijython publishes an extension point called
org.geocraft.ui.ijython.extension. When IJython initializes, all the
extension points for this extension are located and the initialize
method of the classes that implement the IJythonExtension (required by
the extension point contract) is called. Probably some bundle should
add the org.geocraft.ui.foo or whatever to the Jython namespace here.
For an example, please see JyPlot.initialize in
org.geocraft.ui.jyplot. Not sure if this bundle is still there as the
ugly Swing and JFreeChart based JyPlot was replaced with a new cool
one, but I have it here and I can send it to you if needed.

I hope this helps.

Regards,

Dan

Reply all
Reply to author
Forward
0 new messages