Package org.exolab.castor.xml
Class Validator
- java.lang.Object
-
- org.exolab.castor.xml.Validator
-
- All Implemented Interfaces:
TypeValidator
,ClassValidator
- Direct Known Subclasses:
FieldValidator
,XMLClassDescriptorImpl
public class Validator extends java.lang.Object implements ClassValidator
A class which can perform Validation on an Object model. This class uses the ClassDescriptors and FieldDescriptors to perform the validation.- Version:
- $Revision$ $Date: 2005-02-28 17:43:25 -0700 (Mon, 28 Feb 2005) $
- Author:
- Keith Visco
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.util.ResourceBundle
resourceBundle
resource bundle
-
Constructor Summary
Constructors Constructor Description Validator()
Creates a new Validator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
checkUnresolvedIdrefs(ValidationContext context)
void
validate(java.lang.Object object)
Validates the given Object.void
validate(java.lang.Object object, ValidationContext context)
Validates the given Object.
-
-
-
Method Detail
-
validate
public void validate(java.lang.Object object) throws ValidationException
Validates the given Object.- Parameters:
object
- the Object to validate- Throws:
ValidationException
- if validation fails.
-
validate
public void validate(java.lang.Object object, ValidationContext context) throws ValidationException
Validates the given Object.- Specified by:
validate
in interfaceClassValidator
- Specified by:
validate
in interfaceTypeValidator
- Parameters:
object
- the Object to validatecontext
- the ValidationContext to use during validation.- Throws:
ValidationException
- if validation fails.
-
checkUnresolvedIdrefs
public void checkUnresolvedIdrefs(ValidationContext context) throws ValidationException
- Throws:
ValidationException
-
-