org.springmodules.validation.validator
Class AbstractTypeSpecificValidator

java.lang.Object
  extended by org.springmodules.validation.validator.AbstractTypeSpecificValidator

public abstract class AbstractTypeSpecificValidator
extends java.lang.Object

A base class for all Validator implementation that support only one specific type (class).

Author:
Uri Boness

Constructor Summary
AbstractTypeSpecificValidator(java.lang.Class type)
          Constructs a new AbstractTypeSpecificValidator with a given supported type.
 
Method Summary
 boolean supports(java.lang.Class clazz)
          See Validator#supports(Class).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractTypeSpecificValidator

public AbstractTypeSpecificValidator(java.lang.Class type)
Constructs a new AbstractTypeSpecificValidator with a given supported type.

Parameters:
type - The class supported by this validator.
Method Detail

supports

public boolean supports(java.lang.Class clazz)
See Validator#supports(Class).

Returns:
true if the given class is an instance or a sub-type of the type supported by this validator, false otherwise.


Copyright © 2005. All Rights Reserved.