|
| GenericSchemaValidator (const SchemaDocumentType &schemaDocument, StateAllocator *allocator=0, size_t schemaStackCapacity=kDefaultSchemaStackCapacity, size_t documentStackCapacity=kDefaultDocumentStackCapacity) |
| Constructor without output handler. More...
|
|
| GenericSchemaValidator (const SchemaDocumentType &schemaDocument, OutputHandler &outputHandler, StateAllocator *allocator=0, size_t schemaStackCapacity=kDefaultSchemaStackCapacity, size_t documentStackCapacity=kDefaultDocumentStackCapacity) |
| Constructor with output handler. More...
|
|
| ~GenericSchemaValidator () |
| Destructor. More...
|
|
void | Reset () |
| Reset the internal states. More...
|
|
virtual bool | IsValid () const |
| Checks whether the current state is valid. More...
|
|
PointerType | GetInvalidSchemaPointer () const |
| Gets the JSON pointer pointed to the invalid schema. More...
|
|
const Ch * | GetInvalidSchemaKeyword () const |
| Gets the keyword of invalid schema. More...
|
|
PointerType | GetInvalidDocumentPointer () const |
| Gets the JSON pointer pointed to the invalid value. More...
|
|
bool | Null () |
|
bool | Bool (bool b) |
|
bool | Int (int i) |
|
bool | Uint (unsigned u) |
|
bool | Int64 (int64_t i) |
|
bool | Uint64 (uint64_t u) |
|
bool | Double (double d) |
|
bool | RawNumber (const Ch *str, SizeType length, bool copy) |
|
bool | String (const Ch *str, SizeType length, bool copy) |
|
bool | StartObject () |
|
bool | Key (const Ch *str, SizeType len, bool copy) |
|
bool | EndObject (SizeType memberCount) |
|
bool | StartArray () |
|
bool | EndArray (SizeType elementCount) |
|
virtual ISchemaValidator * | CreateSchemaValidator (const SchemaType &root) |
|
virtual void | DestroySchemaValidator (ISchemaValidator *validator) |
|
virtual void * | CreateHasher () |
|
virtual uint64_t | GetHashCode (void *hasher) |
|
virtual void | DestroryHasher (void *hasher) |
|
virtual void * | MallocState (size_t size) |
|
virtual void | FreeState (void *p) |
|
template<typename SchemaDocumentType, typename OutputHandler = BaseReaderHandler<typename SchemaDocumentType::SchemaType::EncodingType>, typename StateAllocator = CrtAllocator>
class GenericSchemaValidator< SchemaDocumentType, OutputHandler, StateAllocator >
JSON Schema Validator.
A SAX style JSON schema validator. It uses a GenericSchemaDocument
to validate SAX events. It delegates the incoming SAX events to an output handler. The default output handler does nothing. It can be reused multiple times by calling Reset()
.
- Template Parameters
-
SchemaDocumentType | Type of schema document. |
OutputHandler | Type of output handler. Default handler does nothing. |
StateAllocator | Allocator for storing the internal validation states. |
Definition at line 145 of file fwd.h.