org.exolab.castor.xml.validators
Class BooleanValidator
java.lang.Object
org.exolab.castor.xml.validators.BooleanValidator
- TypeValidator
public class BooleanValidator
extends java.lang.Object
The Boolean Validation class. This class handles validation
for the boolean type. This will only check that a boolean has the proper fixed value.
$Revision: 1.2 $ $Date: 2003/03/03 09:57:21 $
void | clearFixed() - Clears the fixed value for this BooleanValidator
|
Boolean | getFixed() - Returns the fixed value that boolean validated with this
validator must be equal to.
|
boolean | hasFixed() - Returns true if a fixed value, to validate against, has been
set.
|
void | setFixed(Boolean fixedValue) - Sets the fixed value that boolean validated with this
validator must be equal to.
|
void | setFixed(boolean fixedValue) - Sets the fixed value that boolean validated with this
validator must be equal to.
|
void | validate(Object object) - Validates the given Object.
|
void | validate(Object object, ValidationContext context) - Validates the given Object
|
void | validate(boolean b)
|
BooleanValidator
public BooleanValidator()
Creates a new BooleanValidator with no restrictions
clearFixed
public void clearFixed()
Clears the fixed value for this BooleanValidator
getFixed
public Boolean getFixed()
Returns the fixed value that boolean validated with this
validator must be equal to. A null value is returned
if no fixed value has been specified.
- the fixed value to validate against.
hasFixed
public boolean hasFixed()
Returns true if a fixed value, to validate against, has been
set.
- true if a fixed value has been set.
setFixed
public void setFixed(Boolean fixedValue)
Sets the fixed value that boolean validated with this
validator must be equal to.
fixedValue
- the fixed value a boolean validated with
this validator must be equal to.
setFixed
public void setFixed(boolean fixedValue)
Sets the fixed value that boolean validated with this
validator must be equal to.
fixedValue
- the fixed value a boolean validated with
this validator must be equal to.
validate
public void validate(Object object)
throws ValidationException
Validates the given Object.
object
- the Object to validate
Intalio Inc. (C) 1999-2003. All rights reserved http://www.intalio.com