org.exolab.castor.xml

Class Validator

Implemented Interfaces:
ClassValidator, TypeValidator
Known Direct 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

Constructor Summary

Validator()
Creates a new Validator.

Method Summary

void
checkUnresolvedIdrefs(ValidationContext context)
void
validate(Object object)
Validates the given Object.
void
validate(Object object, ValidationContext context)
Validates the given Object.

Constructor Details

Validator

public Validator()
Creates a new Validator.

Method Details

checkUnresolvedIdrefs

public void checkUnresolvedIdrefs(ValidationContext context)
            throws ValidationException

validate

public void validate(Object object)
            throws ValidationException
Validates the given Object.
Parameters:
object - the Object to validate
Throws:
ValidationException - if validation fails.

validate

public void validate(Object object,
                     ValidationContext context)
            throws ValidationException
Validates the given Object.
Specified by:
validate in interface ClassValidator
validate in interface TypeValidator
Parameters:
object - the Object to validate
context - the ValidationContext to use during validation.
Throws:
ValidationException - if validation fails.

Intalio Inc. (C) 1999-2008. All rights reserved http://www.intalio.com