org.springframework.richclient.form.builder.support
Class ValidationInterceptor

java.lang.Object
  extended by org.springframework.richclient.form.builder.support.AbstractFormComponentInterceptor
      extended by org.springframework.richclient.form.builder.support.ValidationInterceptor
All Implemented Interfaces:
FormComponentInterceptor
Direct Known Subclasses:
OverlayValidationInterceptorFactory.OverlayValidationInterceptor

public abstract class ValidationInterceptor
extends AbstractFormComponentInterceptor

Adds basic functionality to deal with Validation. Guards and messageReceivers can be added to the ValidationResultsModel of the ValidatingFormModel.

Author:
oliverh

Constructor Summary
ValidationInterceptor(FormModel formModel)
           
 
Method Summary
protected  ValidationListener registerGuarded(String propertyName, Guarded guarded)
          Register a guarded object on a specific property.
protected  ValidationListener registerMessageReceiver(String propertyName, Messagable messageReceiver)
          Register a messageReceiver on a specific property.
 
Methods inherited from class org.springframework.richclient.form.builder.support.AbstractFormComponentInterceptor
getFormModel, getInnerComponent, processComponent, processLabel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ValidationInterceptor

public ValidationInterceptor(FormModel formModel)
Parameters:
formModel - the ValidatingFormModel to operate on.
Method Detail

registerMessageReceiver

protected ValidationListener registerMessageReceiver(String propertyName,
                                                     Messagable messageReceiver)
Register a messageReceiver on a specific property. To keep things in sync, it also triggers a first time check. (validationResultsModel can already be populated)

Parameters:
propertyName - property to listen for.
messageReceiver - message capable component.
Returns:
ValidationListener created during the process.

registerGuarded

protected ValidationListener registerGuarded(String propertyName,
                                             Guarded guarded)
Register a guarded object on a specific property. To keep things in sync, it also triggers a first time check. (validationResultsModel can already be populated)

Parameters:
propertyName - property to listen for.
guarded - component that needs guarding.
Returns:
ValidationListener created during the process.


Copyright © 2004-2008 The Spring Framework. All Rights Reserved.