Re: how to call java methods in python

2011-10-04 Thread Alan Meyer
On 10/4/2011 2:39 AM, masood shaik wrote: Hi I am trying to import java method in python. But i am getting the following error. error: ImportError: No module named Calculator Calculator is the name of the class written in java. I am trying to access the methods of that class. Plea

Re: how to call java methods in python

2011-10-04 Thread Steven D'Aprano
On Tue, 04 Oct 2011 00:14:49 -0700, masood shaik wrote: > Hi > I am trying out my hand on accessing java methods in python. here is > my piece of code.. [...] > Now i am trying to access the calculateTip() and its showing import > error. > It works fine when i am running it with jython but why i

Re: how to call java methods in python

2011-10-04 Thread Laszlo Nagy
Please help me Regarding how to create java bridge as how to call a java function from python If you want to call a Java *method* from the C python implementation, then there are many possibilities. For example, you can write your Java program as a service. The Python program can talk to it t

Re: how to call java methods in python

2011-10-04 Thread masood shaik
On Oct 4, 1:16 pm, Chris Rebert wrote: > On Tue, Oct 4, 2011 at 12:14 AM, masood shaik wrote: > > Hi > >  I am trying out my hand on accessing java methods in python. here is > > my piece of code.. > > > Calculator.java > > --- > > public class Calculator { > > >    public Calculator(

Re: how to call java methods in python

2011-10-04 Thread Chris Rebert
On Tue, Oct 4, 2011 at 12:14 AM, masood shaik wrote: > Hi >  I am trying out my hand on accessing java methods in python. here is > my piece of code.. > > Calculator.java > --- > public class Calculator { > >    public Calculator(){ > >    } > >    public double calculateTip(double cos

Re: how to call java methods in python

2011-10-04 Thread masood shaik
Hi I am trying out my hand on accessing java methods in python. here is my piece of code.. Calculator.java --- public class Calculator { public Calculator(){ } public double calculateTip(double cost, double tipPercentage){ return cost * tipPercentage; }

Re: how to call java methods in python

2011-10-03 Thread alex23
On Oct 4, 4:39 pm, masood shaik wrote: > Please help me. Please help us help you. You've given us nothing but an error message. (Which seems to indicate that you're trying 'import Calculator'...) What are you using to call Java methods in Python? Can you provide a small example of code that dem

how to call java methods in python

2011-10-03 Thread masood shaik
Hi I am trying to import java method in python. But i am getting the following error. error: ImportError: No module named Calculator Calculator is the name of the class written in java. I am trying to access the methods of that class. Please help me. -- http://mail.python.org/ma