Re: [Pydev-code] Quick Status Update -- IGNORE PREV MESSAGE
Brought to you by:
fabioz
From: Dana M. <dan...@ya...> - 2004-05-27 16:26:24
|
All, I finally found time to get back onto PyDev. I checked in a wrapper for Jython to support PythonCompletionProcessor.java. Now I'm working to get that to call a couple the same python modules that autocomplete code for PyAlaMode. Currently, I have a very brittle strategy for play purposes only which is to: ... PythonInterpreter interp = initInterpreter() // do whatever init is req // these modules are in the Jython Lib Path // THIS IS NOT A SUSTAINABLE STRATEGY (!) // WHAT WE REALLY WANT IS TO GET THEM FROM A JAR FILE BUNDLED WITH // THE JYTHON ECLIPSE PLUGIN (see more about this later in the message) interp.exec("from PyDev import jintrospect"); PyString command = new PyString( (String) textAtomBeforeTheDot); interp.exec( "theList = jintrospect.getAutoCompleteList( command="+cmd+", locals=locals())"); PyList theList = (PyList) interp.get("theList"); // then, populate the completion proposals and return for (int i = 0; i < theList.__len__(); i++) { propList.add(theList[i]); } ICompletionProposal[] proposals = new ICompletionProposal[propList.size()]; // and fill with list elements propList.toArray(proposals); // Return the proposals return proposals; ... NOW, here's the question I actually want to ask: is ther a way to import Python files from JAR Archives, so that we can make this stand alone without forcing the use to install JYTHON??? There's a tantalising hint in the jython-dev message: http://aspn.activestate.com/ASPN/Mail/Message/Jython-users/2070925 BUT the technique he describes, he says is in the message: http://www.geocrawler.com/archives/3/7017/2001/9/50/6639698/ I can't seem to find that anywhere. Does anyone have insights into this??? ===== _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ _/ Dana Moore _/ _/ BBN Technologies LLC _/ _/ M: 240.350.4196 _/ _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ __________________________________ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/ |