You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Kevin Jiang <k....@jsure.com> on 2004/06/22 07:28:54 UTC
Non-required Param in inherited-binding -- throws exception when inherited param is NOT required
Hi
I have a component like this.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE component-specification
PUBLIC "-//Apache Software Foundation//Tapestry Specification 3.0//EN"
"http://jakarta.apache.org/tapestry/dtd/Tapestry_3_0.dtd">
<component-specification class="AClass" allow-body="yes" allow-informal-parameters="yes">
...
<parameter
name="isSomething"
type="java.lang.Boolean"
direction="custom"
required="no"/>
...
<component id="ifItisSomething" type="Conditional">
<inherited-binding name="condition" parameter-name="isSomething"/>
</component>
...
</component-specification>
After updated to tapestry 3.0.It throwed org.apache.tapestry.ApplicationRuntimeException--Required parameter condition of component
I think it happened because "isSomething" is NOT required. so may or may not have binding with it.
but this worked fine with tapestry3.0 beta.
Any ideas?
Thanks
Kevin
Re: Non-required Param in inherited-binding -- throws exception when
inherited param is NOT required
Posted by Robert Zeigler <rd...@u.arizona.edu>.
Kevin Jiang wrote:
> Hi
>
> I have a component like this.
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE component-specification
> PUBLIC "-//Apache Software Foundation//Tapestry Specification 3.0//EN"
> "http://jakarta.apache.org/tapestry/dtd/Tapestry_3_0.dtd">
> <component-specification class="AClass" allow-body="yes" allow-informal-parameters="yes">
> ...
> <parameter
> name="isSomething"
> type="java.lang.Boolean"
> direction="custom"
> required="no"/>
> ...
> <component id="ifItisSomething" type="Conditional">
> <inherited-binding name="condition" parameter-name="isSomething"/>
> </component>
> ...
>
> </component-specification>
> After updated to tapestry 3.0.It throwed org.apache.tapestry.ApplicationRuntimeException--Required parameter condition of component
> I think it happened because "isSomething" is NOT required. so may or may not have binding with it.
> but this worked fine with tapestry3.0 beta.
>
> Any ideas?
>
> Thanks
>
> Kevin
>
You could try specifying a default value for the parameter...?
Robert
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org