JPype - passing to Java main

Alan Kennedy alanmk at hotmail.com
Tue Aug 14 13:54:58 EDT 2007


> -------------ERROR_-------------
>   File "tester.py", line 10, in <module>
>     com.JPypeTest.main("arg")
> RuntimeError: No matching overloads found. at src/native/common/
> jp_method.cpp:121
> ----------END ERROR-------------

I haven't used jpype, but the signature for java main functions is

public static void main (String [] args)

So try com.JPypeTest.main(["arg"])

Note the addition of square brackets to create a *list* of arguments,
which presumably jpype will transform into a java String[].

Alan.




More information about the Python-list mailing list