org.apache.tapestry.form
Interface ValidatableFieldSupport

All Known Implementing Classes:
ValidatableFieldSupportImpl

public interface ValidatableFieldSupport

Implements the logic used by Requireds for required field checking on rewind and generating client-side logic during render.

Since:
4.0
Author:
Paul Ferraro

Method Summary
 boolean isRequired(ValidatableField field)
          Returns true if this component is required.
 void renderContributions(ValidatableField field, IMarkupWriter writer, IRequestCycle cycle)
          Called during render of the specified component.
 void validate(ValidatableField component, IMarkupWriter writer, IRequestCycle cycle, Object value)
          Called during rewind of the specified component.
 

Method Detail

renderContributions

void renderContributions(ValidatableField field,
                         IMarkupWriter writer,
                         IRequestCycle cycle)
Called during render of the specified component. Renders any contributions from validators.


validate

void validate(ValidatableField component,
              IMarkupWriter writer,
              IRequestCycle cycle,
              Object value)
              throws ValidatorException
Called during rewind of the specified component. Specified value is validated using the component's validators.

Throws:
ValidatorException - if validation fails

isRequired

boolean isRequired(ValidatableField field)
Returns true if this component is required. This usually entails a search of the component's validators.



Copyright © 2006-2008 Apache Software Foundation. All Rights Reserved.