You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Andrew Robinson <an...@gmail.com> on 2006/06/18 02:54:00 UTC
OptionalValidator - Required validator - compound components
After looking more at the source code for the optional validator
framework, it doesn't look to me like it will support data tables,
trees and other complex comonents that render children multiple times.
It walks the component tree looking for required components, but it
will never check rows of a data table for example as it won't iterate
the rows, only the components once. Don't suppose there is a way
around this. I have no idea why JSF has the required attribute instead
of a required validator.
Is this true, or did I miss something?
-Andrew
Re: OptionalValidator - Required validator - compound components
Posted by Martin Marinschek <ma...@gmail.com>.
Yes, tree traversal is not possible.
This is my most wanted feature for JSF 2.0! We could implement something
like this along the lines of invokeOnComponent.
regards,
Martin
On 6/18/06, Andrew Robinson <an...@gmail.com> wrote:
>
> After looking more at the source code for the optional validator
> framework, it doesn't look to me like it will support data tables,
> trees and other complex comonents that render children multiple times.
>
> It walks the component tree looking for required components, but it
> will never check rows of a data table for example as it won't iterate
> the rows, only the components once. Don't suppose there is a way
> around this. I have no idea why JSF has the required attribute instead
> of a required validator.
>
> Is this true, or did I miss something?
>
> -Andrew
>
--
http://www.irian.at
Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German
Professional Support for Apache MyFaces
Re: OptionalValidator - Required validator - compound components
Posted by Cagatay Civici <ca...@gmail.com>.
Hi,
Yes, tree traversing won't work in case of a datatable. I always think
required attribute is a mistake, it should be a validator instead.
Cagatay,
On 6/18/06, Andrew Robinson <an...@gmail.com> wrote:
>
> After looking more at the source code for the optional validator
> framework, it doesn't look to me like it will support data tables,
> trees and other complex comonents that render children multiple times.
>
> It walks the component tree looking for required components, but it
> will never check rows of a data table for example as it won't iterate
> the rows, only the components once. Don't suppose there is a way
> around this. I have no idea why JSF has the required attribute instead
> of a required validator.
>
> Is this true, or did I miss something?
>
> -Andrew
>