You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Jacob Arnold <ja...@nmcourts.com> on 2007/08/22 21:45:52 UTC

DynamicSelectionList Hivemind NullPointerException

I'm trying to get the DynamicSelectionList component working in an 
existing Tapestry 4.0 project.
http://lombok.demon.co.uk/tapestry4Demo/

I copied all of the source files from the custom class example into my 
own packages, but when I try to submit the form on the page, I get this 
error:

org.apache.hivemind.ApplicationRuntimeException
Parameter name must not be null.

Any ideas? Thanks!

J


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Shing Hing Man <ma...@yahoo.com>.
I have just downoloaded
manTap4Library-1.3-src.jar from Tassel  and verified
all the files 
are same as my local copy. I am running Tap 4.0.2 
as well and the component works.

It is strange that you have problem with it.
Anyway, I am glad you have found a solution.

Shing 



--- Jacob Arnold <ja...@nmcourts.com> wrote:

> I was able to fix the NullPointer by adding this
> code 
> abovecycle.getParameter(_childId) in the
> rewindFormComponent() method of 
> DynamicSelectionList:
> 
>     String suffix = "";
>     if (getIndex() > 0) {
>       suffix = "_" + (getIndex() - 1);
>     }
>     _childId = getId() + suffix;
> 
> It looks like it's working perfectly now.
> 
> Jacob
> 
> 
> 
> Ulrich Stärk wrote:
> > It seems to me that this component is broken. When
> I try to test this 
> > my browser complains about javascript errors and
> the child list stays 
> > empty. I don't know whats wrong with it and I'm
> too lazy to debug it. 
> > You should contact the author of the component to
> get a fix.
> >
> > Uli
> 
> 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail:
> users-help@tapestry.apache.org
> 
> 


Home page : http://www.lombok.demon.co.uk/



      ___________________________________________________________
Yahoo! Answers - Got a question? Someone out there knows the answer. Try it
now.
http://uk.answers.yahoo.com/ 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Jacob Arnold <ja...@nmcourts.com>.
I was able to fix the NullPointer by adding this code 
abovecycle.getParameter(_childId) in the rewindFormComponent() method of 
DynamicSelectionList:

    String suffix = "";
    if (getIndex() > 0) {
      suffix = "_" + (getIndex() - 1);
    }
    _childId = getId() + suffix;

It looks like it's working perfectly now.

Jacob



Ulrich Stärk wrote:
> It seems to me that this component is broken. When I try to test this 
> my browser complains about javascript errors and the child list stays 
> empty. I don't know whats wrong with it and I'm too lazy to debug it. 
> You should contact the author of the component to get a fix.
>
> Uli



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Ulrich Stärk <ul...@spielviel.de>.
It seems to me that this component is broken. When I try to test this my 
browser complains about javascript errors and the child list stays 
empty. I don't know whats wrong with it and I'm too lazy to debug it. 
You should contact the author of the component to get a fix.

Uli

Jacob Arnold schrieb:
> Of course. Sorry :-)
> 
> 
> org.apache.hivemind.ApplicationRuntimeException
> Parameter name must not be null.
> 
> component:     $TestDSLComponent2_24@f96845[TestDSLComponent2]
> location:     context:/WEB-INF/html/TestDSLComponent2.page, line 7, 
> column 77
> 2    <!DOCTYPE page-specification PUBLIC
> 3    "-//Apache Software Foundation//Tapestry Specification 4.0//EN"
> 4    "http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd">
> 5   6   7    <page-specification 
> class="gov.nmcourts.caselookup.pages.TestDSLComponent2">
> 8   9    <!-- component -->
> 10    <component id="makeSelection" type="PropertySelection">
> 11    <binding name="value" value="ognl:make"/>
> 12    <binding name="model" value="ognl:makeModel"/>
> 
> java.lang.NullPointerException
> Parameter name must not be null.
> Stack Trace:
> 
>    * org.apache.hivemind.util.Defense.notNull(Defense.java:41)
>    * 
> org.apache.tapestry.util.QueryParameterMap.getParameterValue(QueryParameterMap.java:82) 
> 
>    * 
> org.apache.tapestry.engine.RequestCycle.getParameter(RequestCycle.java:636)
>    * 
> man.library.components.dynamicSelectionList.DynamicSelectionList.rewindFormComponent(DynamicSelectionList.java:165) 
> 
>    * 
> org.apache.tapestry.form.AbstractFormComponent.renderComponent(AbstractFormComponent.java:114) 
> 
>    * 
> org.apache.tapestry.AbstractComponent.render(AbstractComponent.java:617)
>    * 
> org.apache.tapestry.AbstractComponent.renderBody(AbstractComponent.java:434) 
> 
>    * 
> org.apache.tapestry.form.FormSupportImpl.rewind(FormSupportImpl.java:573)
>    * org.apache.tapestry.form.Form.renderComponent(Form.java:226)
>    * 
> org.apache.tapestry.AbstractComponent.render(AbstractComponent.java:617)
>    * org.apache.tapestry.form.Form.rewind(Form.java:327)
>    * 
> org.apache.tapestry.engine.RequestCycle.rewindForm(RequestCycle.java:439)
>    * org.apache.tapestry.form.Form.trigger(Form.java:338)
>    * 
> org.apache.tapestry.engine.DirectService.triggerComponent(DirectService.java:146) 
> 
>    * 
> org.apache.tapestry.engine.DirectService.service(DirectService.java:132)
>    * $IEngineService_1148ef6cb13.service($IEngineService_1148ef6cb13.java)
>    * 
> org.apache.tapestry.services.impl.EngineServiceOuterProxy.service(EngineServiceOuterProxy.java:66) 
> 
>    * 
> org.apache.tapestry.engine.AbstractEngine.service(AbstractEngine.java:248)
>    * 
> org.apache.tapestry.services.impl.InvokeEngineTerminator.service(InvokeEngineTerminator.java:60) 
> 
>    * 
> $WebRequestServicer_1148ef6caee.service($WebRequestServicer_1148ef6caee.java) 
> 
>    * 
> org.apache.tapestry.services.impl.DisableCachingFilter.service(DisableCachingFilter.java:48) 
> 
>    * 
> $WebRequestServicerFilter_1148ef6caf0.service($WebRequestServicerFilter_1148ef6caf0.java) 
> 
>    * 
> $WebRequestServicer_1148ef6caf2.service($WebRequestServicer_1148ef6caf2.java) 
> 
>    * 
> $WebRequestServicer_1148ef6caea.service($WebRequestServicer_1148ef6caea.java) 
> 
>    * 
> org.apache.tapestry.services.impl.WebRequestServicerPipelineBridge.service(WebRequestServicerPipelineBridge.java:56) 
> 
>    * 
> $ServletRequestServicer_1148ef6cad0.service($ServletRequestServicer_1148ef6cad0.java) 
> 
>    * 
> org.apache.tapestry.request.DecodedRequestInjector.service(DecodedRequestInjector.java:55) 
> 
>    * 
> $ServletRequestServicerFilter_1148ef6cacc.service($ServletRequestServicerFilter_1148ef6cacc.java) 
> 
>    * 
> $ServletRequestServicer_1148ef6cad2.service($ServletRequestServicer_1148ef6cad2.java) 
> 
>    * 
> org.apache.tapestry.multipart.MultipartDecoderFilter.service(MultipartDecoderFilter.java:52) 
> 
>    * 
> $ServletRequestServicerFilter_1148ef6caca.service($ServletRequestServicerFilter_1148ef6caca.java) 
> 
>    * 
> $ServletRequestServicer_1148ef6cad2.service($ServletRequestServicer_1148ef6cad2.java) 
> 
>    * 
> org.apache.tapestry.services.impl.SetupRequestEncoding.service(SetupRequestEncoding.java:53) 
> 
>    * 
> $ServletRequestServicerFilter_1148ef6cace.service($ServletRequestServicerFilter_1148ef6cace.java) 
> 
>    * 
> $ServletRequestServicer_1148ef6cad2.service($ServletRequestServicer_1148ef6cad2.java) 
> 
>    * 
> $ServletRequestServicer_1148ef6cac4.service($ServletRequestServicer_1148ef6cac4.java) 
> 
>    * 
> org.apache.tapestry.ApplicationServlet.doService(ApplicationServlet.java:123) 
> 
>    * 
> org.apache.tapestry.ApplicationServlet.doPost(ApplicationServlet.java:168)
> ...
> 
> I'm guessing I have some strange configuration, since I know this code 
> works elsewhere. Here's how I specify the library in my .application file:
> 
> <library id="man" 
> specification-path="classpath:/man/library/ManSH.library"/>
> 
> J
> 
> 
> Ulrich Stärk wrote:
>> Please give us the exact error message (doesn't need to be the whole 
>> stack trace but a few more lines from which we can see at which point 
>> the exception is thrown would be helpful...).
>>
>> Uli
>>
>> Jacob Arnold schrieb:
>>> Thanks for the quick response. The source is exactly as here except I 
>>> changed the package names:
>>>
>>> http://lombok.demon.co.uk/tapestry4Demo/pages/dynamicSelectionList/TestDSLComponent2Source.html 
>>>
>>>
>>> The error occurs on line 7 of TestDSLComponent2.page:
>>>
>>> <page-specification 
>>> class="gov.nmcourts.caselookup.pages.TestDSLComponent2">
>>>
>>> Thanks,
>>> Jacob 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Jacob Arnold <ja...@nmcourts.com>.
Of course. Sorry :-)


org.apache.hivemind.ApplicationRuntimeException
Parameter name must not be null.

component:     $TestDSLComponent2_24@f96845[TestDSLComponent2]
location:     context:/WEB-INF/html/TestDSLComponent2.page, line 7, 
column 77
2    <!DOCTYPE page-specification PUBLIC
3    "-//Apache Software Foundation//Tapestry Specification 4.0//EN"
4    "http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd">
5   
6   
7    <page-specification 
class="gov.nmcourts.caselookup.pages.TestDSLComponent2">
8   
9    <!-- component -->
10    <component id="makeSelection" type="PropertySelection">
11    <binding name="value" value="ognl:make"/>
12    <binding name="model" value="ognl:makeModel"/>

java.lang.NullPointerException
Parameter name must not be null.
Stack Trace:

    * org.apache.hivemind.util.Defense.notNull(Defense.java:41)
    * 
org.apache.tapestry.util.QueryParameterMap.getParameterValue(QueryParameterMap.java:82)
    * 
org.apache.tapestry.engine.RequestCycle.getParameter(RequestCycle.java:636)
    * 
man.library.components.dynamicSelectionList.DynamicSelectionList.rewindFormComponent(DynamicSelectionList.java:165)
    * 
org.apache.tapestry.form.AbstractFormComponent.renderComponent(AbstractFormComponent.java:114)
    * 
org.apache.tapestry.AbstractComponent.render(AbstractComponent.java:617)
    * 
org.apache.tapestry.AbstractComponent.renderBody(AbstractComponent.java:434)
    * 
org.apache.tapestry.form.FormSupportImpl.rewind(FormSupportImpl.java:573)
    * org.apache.tapestry.form.Form.renderComponent(Form.java:226)
    * 
org.apache.tapestry.AbstractComponent.render(AbstractComponent.java:617)
    * org.apache.tapestry.form.Form.rewind(Form.java:327)
    * 
org.apache.tapestry.engine.RequestCycle.rewindForm(RequestCycle.java:439)
    * org.apache.tapestry.form.Form.trigger(Form.java:338)
    * 
org.apache.tapestry.engine.DirectService.triggerComponent(DirectService.java:146)
    * 
org.apache.tapestry.engine.DirectService.service(DirectService.java:132)
    * $IEngineService_1148ef6cb13.service($IEngineService_1148ef6cb13.java)
    * 
org.apache.tapestry.services.impl.EngineServiceOuterProxy.service(EngineServiceOuterProxy.java:66)
    * 
org.apache.tapestry.engine.AbstractEngine.service(AbstractEngine.java:248)
    * 
org.apache.tapestry.services.impl.InvokeEngineTerminator.service(InvokeEngineTerminator.java:60)
    * 
$WebRequestServicer_1148ef6caee.service($WebRequestServicer_1148ef6caee.java)
    * 
org.apache.tapestry.services.impl.DisableCachingFilter.service(DisableCachingFilter.java:48)
    * 
$WebRequestServicerFilter_1148ef6caf0.service($WebRequestServicerFilter_1148ef6caf0.java)
    * 
$WebRequestServicer_1148ef6caf2.service($WebRequestServicer_1148ef6caf2.java)
    * 
$WebRequestServicer_1148ef6caea.service($WebRequestServicer_1148ef6caea.java)
    * 
org.apache.tapestry.services.impl.WebRequestServicerPipelineBridge.service(WebRequestServicerPipelineBridge.java:56)
    * 
$ServletRequestServicer_1148ef6cad0.service($ServletRequestServicer_1148ef6cad0.java)
    * 
org.apache.tapestry.request.DecodedRequestInjector.service(DecodedRequestInjector.java:55)
    * 
$ServletRequestServicerFilter_1148ef6cacc.service($ServletRequestServicerFilter_1148ef6cacc.java)
    * 
$ServletRequestServicer_1148ef6cad2.service($ServletRequestServicer_1148ef6cad2.java)
    * 
org.apache.tapestry.multipart.MultipartDecoderFilter.service(MultipartDecoderFilter.java:52)
    * 
$ServletRequestServicerFilter_1148ef6caca.service($ServletRequestServicerFilter_1148ef6caca.java)
    * 
$ServletRequestServicer_1148ef6cad2.service($ServletRequestServicer_1148ef6cad2.java)
    * 
org.apache.tapestry.services.impl.SetupRequestEncoding.service(SetupRequestEncoding.java:53)
    * 
$ServletRequestServicerFilter_1148ef6cace.service($ServletRequestServicerFilter_1148ef6cace.java)
    * 
$ServletRequestServicer_1148ef6cad2.service($ServletRequestServicer_1148ef6cad2.java)
    * 
$ServletRequestServicer_1148ef6cac4.service($ServletRequestServicer_1148ef6cac4.java)
    * 
org.apache.tapestry.ApplicationServlet.doService(ApplicationServlet.java:123)
    * 
org.apache.tapestry.ApplicationServlet.doPost(ApplicationServlet.java:168)
...

I'm guessing I have some strange configuration, since I know this code 
works elsewhere. Here's how I specify the library in my .application file:

<library id="man" 
specification-path="classpath:/man/library/ManSH.library"/>

J


Ulrich Stärk wrote:
> Please give us the exact error message (doesn't need to be the whole 
> stack trace but a few more lines from which we can see at which point 
> the exception is thrown would be helpful...).
>
> Uli
>
> Jacob Arnold schrieb:
>> Thanks for the quick response. The source is exactly as here except I 
>> changed the package names:
>>
>> http://lombok.demon.co.uk/tapestry4Demo/pages/dynamicSelectionList/TestDSLComponent2Source.html 
>>
>>
>> The error occurs on line 7 of TestDSLComponent2.page:
>>
>> <page-specification 
>> class="gov.nmcourts.caselookup.pages.TestDSLComponent2">
>>
>> Thanks,
>> Jacob 



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Ulrich Stärk <ul...@spielviel.de>.
Please give us the exact error message (doesn't need to be the whole 
stack trace but a few more lines from which we can see at which point 
the exception is thrown would be helpful...).

Uli

Jacob Arnold schrieb:
> Thanks for the quick response. The source is exactly as here except I 
> changed the package names:
> 
> http://lombok.demon.co.uk/tapestry4Demo/pages/dynamicSelectionList/TestDSLComponent2Source.html 
> 
> 
> The error occurs on line 7 of TestDSLComponent2.page:
> 
> <page-specification 
> class="gov.nmcourts.caselookup.pages.TestDSLComponent2">
> 
> Thanks,
> Jacob
> 
> 
> Ulrich Stärk wrote:
>> Well, some mandatory parameter of some component must not be null :-)
>>
>> How about giving us a bit more? Page template, page class, line in the 
>> template at which the error occurs...
>>
>> Uli
>>
>> Jacob Arnold schrieb:
>>> I'm trying to get the DynamicSelectionList component working in an 
>>> existing Tapestry 4.0 project.
>>> http://lombok.demon.co.uk/tapestry4Demo/
>>>
>>> I copied all of the source files from the custom class example into 
>>> my own packages, but when I try to submit the form on the page, I get 
>>> this error:
>>>
>>> org.apache.hivemind.ApplicationRuntimeException
>>> Parameter name must not be null.
>>>
>>> Any ideas? Thanks!
>>>
>>> J
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Jacob Arnold <ja...@nmcourts.com>.
Thanks for the quick response. The source is exactly as here except I 
changed the package names:

http://lombok.demon.co.uk/tapestry4Demo/pages/dynamicSelectionList/TestDSLComponent2Source.html

The error occurs on line 7 of TestDSLComponent2.page:

<page-specification class="gov.nmcourts.caselookup.pages.TestDSLComponent2">

Thanks,
Jacob


Ulrich Stärk wrote:
> Well, some mandatory parameter of some component must not be null :-)
>
> How about giving us a bit more? Page template, page class, line in the 
> template at which the error occurs...
>
> Uli
>
> Jacob Arnold schrieb:
>> I'm trying to get the DynamicSelectionList component working in an 
>> existing Tapestry 4.0 project.
>> http://lombok.demon.co.uk/tapestry4Demo/
>>
>> I copied all of the source files from the custom class example into 
>> my own packages, but when I try to submit the form on the page, I get 
>> this error:
>>
>> org.apache.hivemind.ApplicationRuntimeException
>> Parameter name must not be null.
>>
>> Any ideas? Thanks!
>>
>> J
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: DynamicSelectionList Hivemind NullPointerException

Posted by Ulrich Stärk <ul...@spielviel.de>.
Well, some mandatory parameter of some component must not be null :-)

How about giving us a bit more? Page template, page class, line in the 
template at which the error occurs...

Uli

Jacob Arnold schrieb:
> I'm trying to get the DynamicSelectionList component working in an 
> existing Tapestry 4.0 project.
> http://lombok.demon.co.uk/tapestry4Demo/
> 
> I copied all of the source files from the custom class example into my 
> own packages, but when I try to submit the form on the page, I get this 
> error:
> 
> org.apache.hivemind.ApplicationRuntimeException
> Parameter name must not be null.
> 
> Any ideas? Thanks!
> 
> J
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org