Bugs item #584393, was opened at 2002-07-21 01:25
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=104754&aid=584393&group_id=4754
Category: Tapestry
Group: bug
>Status: Deleted
>Resolution: Duplicate
Priority: 5
Submitted By: Tom Davies (tomdavies)
Assigned to: Howard Lewis Ship (hship)
Summary: string-binding NPE
Initial Comment:
I have a ValidField with the binding:
<string-binding name="displayName"
key="investigationListFilter-investigationName"/>
When the page loads I get:
java.lang.NullPointerException Stack Trace:
*
net.sf.tapestry.AbstractComponent.getString(AbstractComponent.java:942)
*
net.sf.tapestry.binding.StringBinding.getObject(StringBinding.java:69)
*
net.sf.tapestry.binding.AbstractBinding.getString(AbstractBinding.java:112)
*
net.sf.tapestry.valid.ValidField.setDisplayNameBinding(ValidField.java:182)
*
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
*
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
*
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
* java.lang.reflect.Method.invoke(Method.java:324)
*
net.sf.tapestry.util.prop.PropertyAccessor.set(PropertyAccessor.java:168)
*
net.sf.tapestry.AbstractComponent.setBinding(AbstractComponent.java:676)
*
net.sf.tapestry.pageload.PageLoader.bind(PageLoader.java:184)
*
net.sf.tapestry.pageload.PageLoader.setBindings(PageLoader.java:518)
*
net.sf.tapestry.pageload.PageLoader.setBindings(PageLoader.java:520)
*
net.sf.tapestry.pageload.PageLoader.loadPage(PageLoader.java:465)
*
net.sf.tapestry.pageload.PageSource.getPage(PageSource.java:178)
*
net.sf.tapestry.engine.RequestCycle.getPage(RequestCycle.java:223)
*
au.com.oakton.item.ui.CommandComponent.doCommand(CommandComponent.java:21)
I think this is because AbstractComponent.getString()
uses the engine of the current page to find the i18n
strings, and the page does not get attach()ed until
after its properties have been bound.
This could probably be fixed by moving the attach()
into PageLoader.loadPage()
----------------------------------------------------------------------
>Comment By: Howard Lewis Ship (hship)
Date: 2002-07-21 08:00
Message:
Logged In: YES
user_id=26816
Duplicate of [ 574792 ] localized strings don't work
Fixed in 2.2
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=104754&aid=584393&group_id=4754
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Tapestry-developer mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/tapestry-developer