From: <bc...@wo...> - 2001-08-06 19:46:11
|
[Fred Sells] >I have a jar file that I developed in java1.3 using JBuilder and the >compiler provided with it (I assume jdk 1.3). When I import that file while >running jython, all is well HOWEVER when I jythonc my main (using --all >--jar Main.py) and run it -- I can import the package but it does not have >any visible contents. > >i.e. > >import ezjava >print dir(ezjava) > >["__name__"] is all I get > >the classes in ezjava are all public; I'm stumped. You would get the same result if you use tried it on any other java package. It isn't a problem with your ezjava.jar file. If you want to use dynamic reflection in a staticly compiled program you can try adding code like this somewhere in your Main.py file: if 1 == 0: from ezjava import * It doesn't have to executed as long as the compiler can see the code. Also look for the text Required packages: ezjava* in the jythonc output. regards, finn |