compiler construction - Accessing a Python object from Java Code in Jython 2.5 -


i have application using jython 2.1. in app using jythonc convert python scripts java classes , include these classes in webapp other. able assign package name python scripts , access these classes other java class.

now plan migrate jython 2.5. jython 2.5 has removed support jythonc. tried use

jython -m compileall /path/to/my/python/scripts.  

when compiled bytecode files in same folder. each of files have names myclass$py.class (where python file myclass.py).

my questions -

  1. first of can access these classes in normal java class?
  2. if so, class name should use ? when use new myclass() code not compile.
  3. is there way, can assign / force package name or class name generated bytecode compileall?

note -

  • i need upgrade jython 2.5 because need newer versions of python supports.
  • i stick pre-compiling python code bytecode, want optimizations on bytecode. recommended object factory method last resort. assuming object factory approach not allow me process generated bytecode.

any appreciated.


Comments

Popular posts from this blog

android - getbluetoothservice() called with no bluetoothmanagercallback -

sql - ASP.NET SqlDataSource, like on SelectCommand -

ios - Undefined symbols for architecture armv7: "_OBJC_CLASS_$_SSZipArchive" -