You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Patrick <pa...@gmail.com> on 2010/04/12 20:57:12 UTC

any reason a groovy file can't execute my java class?

I made a little java class but it won't execute for me in groovy, I
can execute other classes

orh = new OrderReadHelper(); //i can execute this

z = new NextPickupDateUpdater();  //this is my class, it doesn't
complain, but it doesn't execute, inspecting the value gives a memory
address,
numdays = z.update();  //here it breaks


org.ofbiz.widget.screen.ScreenRenderException: Error rendering screen
[component://ecommerce/widget/CommonScreens.xml#main-decorator]:
groovy.lang.MissingMethodException: No signature of method:
NextPickupDateUpdater.update() is applicable for argument types: ()
values: {} (No signature of method: NextPickupDateUpdater.update() is
applicable for argument types: () values: {})

Re: any reason a groovy file can't execute my java class?

Posted by Jacques Le Roux <ja...@les7arts.com>.
Yes, that's a problem indeed

Jacques

From: "Patrick" <pa...@gmail.com>
>I guess you can't have a groovy file with the same name as your java
> class file  :(
> 
> On Mon, Apr 12, 2010 at 2:01 PM, Adrian Crum <ad...@hlmksw.com> wrote:
>> Make sure the update method is public, and that it takes no arguments and
>> returns a number.
>>
>> -Adrian
>>
>> Patrick wrote:
>>>
>>> I made a little java class but it won't execute for me in groovy, I
>>> can execute other classes
>>>
>>> orh = new OrderReadHelper(); //i can execute this
>>>
>>> z = new NextPickupDateUpdater(); //this is my class, it doesn't
>>> complain, but it doesn't execute, inspecting the value gives a memory
>>> address,
>>> numdays = z.update(); //here it breaks
>>>
>>>
>>> org.ofbiz.widget.screen.ScreenRenderException: Error rendering screen
>>> [component://ecommerce/widget/CommonScreens.xml#main-decorator]:
>>> groovy.lang.MissingMethodException: No signature of method:
>>> NextPickupDateUpdater.update() is applicable for argument types: ()
>>> values: {} (No signature of method: NextPickupDateUpdater.update() is
>>> applicable for argument types: () values: {})
>>>
>>
>


Re: any reason a groovy file can't execute my java class?

Posted by Patrick <pa...@gmail.com>.
I guess you can't have a groovy file with the same name as your java
class file  :(

On Mon, Apr 12, 2010 at 2:01 PM, Adrian Crum <ad...@hlmksw.com> wrote:
> Make sure the update method is public, and that it takes no arguments and
> returns a number.
>
> -Adrian
>
> Patrick wrote:
>>
>> I made a little java class but it won't execute for me in groovy, I
>> can execute other classes
>>
>> orh = new OrderReadHelper(); //i can execute this
>>
>> z = new NextPickupDateUpdater();  //this is my class, it doesn't
>> complain, but it doesn't execute, inspecting the value gives a memory
>> address,
>> numdays = z.update();  //here it breaks
>>
>>
>> org.ofbiz.widget.screen.ScreenRenderException: Error rendering screen
>> [component://ecommerce/widget/CommonScreens.xml#main-decorator]:
>> groovy.lang.MissingMethodException: No signature of method:
>> NextPickupDateUpdater.update() is applicable for argument types: ()
>> values: {} (No signature of method: NextPickupDateUpdater.update() is
>> applicable for argument types: () values: {})
>>
>

Re: any reason a groovy file can't execute my java class?

Posted by Adrian Crum <ad...@hlmksw.com>.
Make sure the update method is public, and that it takes no arguments 
and returns a number.

-Adrian

Patrick wrote:
> I made a little java class but it won't execute for me in groovy, I
> can execute other classes
> 
> orh = new OrderReadHelper(); //i can execute this
> 
> z = new NextPickupDateUpdater();  //this is my class, it doesn't
> complain, but it doesn't execute, inspecting the value gives a memory
> address,
> numdays = z.update();  //here it breaks
> 
> 
> org.ofbiz.widget.screen.ScreenRenderException: Error rendering screen
> [component://ecommerce/widget/CommonScreens.xml#main-decorator]:
> groovy.lang.MissingMethodException: No signature of method:
> NextPickupDateUpdater.update() is applicable for argument types: ()
> values: {} (No signature of method: NextPickupDateUpdater.update() is
> applicable for argument types: () values: {})
> 

Re: any reason a groovy file can't execute my java class?

Posted by Anurag Walia <wa...@hotmail.com>.
Hi,

Some times if the  java file exist inside hot-deploy then problem come like
this.
can you specify the path of your java and groovy file.

Regards
Anurag Walia 
-- 
View this message in context: http://n4.nabble.com/any-reason-a-groovy-file-can-t-execute-my-java-class-tp1837571p1837980.html
Sent from the OFBiz - User mailing list archive at Nabble.com.