cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vadim Gritsenko <va...@reverycodes.com>
Subject Re: cvs commit: cocoon-2.1/src/blocks/forms/java/org/apache/cocoon/forms/formmodel Action.java AggregateField.java BooleanField.java Field.java Form.java Messages.java MultiValueField.java Output.java Repeater.java Union.java Upload.java
Date Fri, 30 Apr 2004 14:28:51 GMT
Bruno Dumon wrote:

>On Fri, 2004-04-30 at 16:15, Vadim Gritsenko wrote:
>  
>
>>bruno@apache.org wrote:
>>
>>    
>>
>>> Drop FormContext from validate method.
>>>
>>>      
>>>
>>May be this was already answered, but how, say, validator can perform 
>>City/State/Zip validation against zip database? Would it need this 
>>FormContext or it has access to something else?
>>    
>>
>
>FormContext only contains the request and the locale, so that wouldn't
>have helped much.
>
>If you add validators to the form instance (ie calling
>widget.addValidator in the controller/flowscript code) you can make
>yourself that the validator has access to all it needs.
>  
>

Yep.


>For the "static" validators defined as part of the form definition, we
>could apply the Avalon lifecycle to them so they can get a
>ServiceManager.
>

This last one sounds good.

Thanks for explanation
Vadim


Mime
View raw message