31.01.2011 19:20, Laurent Carbonnaux kirjoitti:
Hi,

I'm new in Jython and I'm facing some troubles:

I'd like to call a method that have a (*values) as parameter
How can I call it from java thru Jython?
I have made a method like (String... values), but python receive an array of String as a single and first parameter of *values
String... is really syntactic sugar for String[], which is how it is behind the scenes. Use it accordingly.

mymodule.py 

 def log(self, *values):
    for mes in values:
        print mes

public void callmymodule(String... values)
    ...
    mymodule().log("val1", "val2", "val3")

output is :
array(java.lang.String, [u'val1', u'val2', u'val3'])

Does anyone can help me?
Regards,
Laurent.
------------------------------------------------------------------------------ Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)! Finally, a world-class log management solution at an even better price-free! Download using promo code Free_Logger_4_Dev2Dev. Offer expires February 28th, so secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsight-sfd2d
_______________________________________________ Jython-users mailing list Jython-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jython-users