cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sylvain Wallez <sylv...@apache.org>
Subject Re: Context.javaToJS
Date Wed, 11 May 2005 13:20:31 GMT
Leszek Gawron wrote:

> Are there any side effects for changing the implementation of
> FOM_Cocoon.jsFunction_setupObject from:
>
>> public Object jsFunction_setupObject(Object obj) throws Exception {
>>     LifecycleHelper.setupComponent(
>>          unwrap(obj),
>>          this.getLogger(),
>>          this.getAvalonContext(),
>>          this.getServiceManager(),
>>          null,// configuration
>>          true);
>>      return obj;
>> }
>
>
> to:
>
>> public Object jsFunction_setupObject(Object obj) throws Exception {
>>     LifecycleHelper.setupComponent(
>>          unwrap(obj),
>>          this.getLogger(),
>>          this.getAvalonContext(),
>>          this.getServiceManager(),
>>          null,// configuration
>>          true);
>>      return org.mozilla.javascript.Context.javaToJS(obj, 
>> getParentScope());
>> }
>
> this fix stops Rhino nagging about naked java object sent to flowscript.
>
> Can I commit?


Yes, sure!

Sylvain

-- 
Sylvain Wallez                        Anyware Technologies
http://apache.org/~sylvain            http://anyware-tech.com
Apache Software Foundation Member     Research & Technology Director


Mime
View raw message