org.hyperic.hq.ui.validator
Class IdenticalValidator
java.lang.Object
org.hyperic.hq.ui.validator.BaseValidator
org.hyperic.hq.ui.validator.IdenticalValidator
public class IdenticalValidator
- extends BaseValidator
This class is for use in the commons validation package to
validate two identical fields.
Method Summary |
boolean |
validate(java.lang.Object bean,
org.apache.commons.validator.ValidatorAction va,
org.apache.commons.validator.Field field,
org.apache.struts.action.ActionMessages msgs,
javax.servlet.http.HttpServletRequest request)
Validates if two fields are equal in terms of String's equal()
function. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IdenticalValidator
public IdenticalValidator()
validate
public boolean validate(java.lang.Object bean,
org.apache.commons.validator.ValidatorAction va,
org.apache.commons.validator.Field field,
org.apache.struts.action.ActionMessages msgs,
javax.servlet.http.HttpServletRequest request)
- Validates if two fields are equal in terms of String's equal()
function.
Example of use:
secondProperty
password2
- Specified by:
validate
in class BaseValidator
msgs
- Any errors should be stored in the ActionErrors collection.request
- The current http request that is being processed.
- Returns:
- Returns true if the fields property and property2 are
identical.
Copyright © 2004-2006 Hyperic, Inc. support@hyperic.net, All Rights Reserved.