xmltooling 1.5.6

- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
xmltooling::ValidatorSuite Class Reference

A collection of validators that can be applied to an XMLObject and its children. More...

`#include <xmltooling/validation/ValidatorSuite.h>`

## Public Member Functions
| ValidatorSuite (const char *id)
| Creates a new suite. More...
const char * | getId ()
| Gets a unique ID for this suite. More...
void | validate (const XMLObject *xmlObject) const
| Evaluates the registered validators against the given XMLObject and it's children. More...
void | registerValidator (const QName &key, Validator *validator)
| Registers a new validator for the given key. More...
void | deregisterValidators (const QName &key)
| Deregisters validators. More...
void | destroyValidators ()
| Unregisters and destroys all registered validators.

## Detailed Description

A collection of validators that can be applied to an XMLObject and its children.

These collections can represent usage specific checks, such as those outlined in schemas or profiles of specific XML specifications.

Registered Validators must be stateless. Validators are fetched based on schema type and element name, in that order.

## Constructor & Destructor Documentation

xmltooling::ValidatorSuite::ValidatorSuite | ( | const char * | id | ) |

Creates a new suite.

Parameters

  id | an identifier for the suite

## Member Function Documentation

void xmltooling::ValidatorSuite::deregisterValidators | ( | const QName & | key | ) |

Deregisters validators.

Parameters

  key | the key for the validators to be deregistered

const char* xmltooling::ValidatorSuite::getId | ( |  | ) |

Gets a unique ID for this suite.

Returns
  a unique ID for this suite

void xmltooling::ValidatorSuite::registerValidator | ( | const QName & | key,
|  | Validator * | validator
| ) |  |

Registers a new validator for the given key.

Parameters

  key | the key used to retrieve the validator
  validator | the validator

void xmltooling::ValidatorSuite::validate | ( | const XMLObject * | xmlObject | ) | const

Evaluates the registered validators against the given XMLObject and it's children.

Parameters

  xmlObject | the XMLObject tree to validate

Exceptions

  ValidationException | thrown if the element tree is not valid

The documentation for this class was generated from the following file:

- xmltooling/validation/ValidatorSuite.h