Classes | Public Types | Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | Friends | List of all members
internal::Schema< SchemaDocumentType > Class Template Reference

#include <schema.h>

Classes

struct  PatternProperty
 
struct  Property
 
struct  SchemaArray
 

Public Types

typedef SchemaDocumentType::AllocatorType AllocatorType
 
typedef EncodingType::Ch Ch
 
typedef SchemaValidationContext< SchemaDocumentType > Context
 
typedef ValueType::EncodingType EncodingType
 
typedef SchemaDocumentType::PointerType PointerType
 
typedef Schema< SchemaDocumentType > SchemaType
 
typedef GenericValue< EncodingType, AllocatorTypeSValue
 
typedef SchemaDocumentType::ValueType ValueType
 

Public Member Functions

bool BeginValue (Context &context) const
 
bool Bool (Context &context, bool) const
 
bool Double (Context &context, double d) const
 
bool EndArray (Context &context, SizeType elementCount) const
 
bool EndObject (Context &context, SizeType memberCount) const
 
RAPIDJSON_FORCEINLINE bool EndValue (Context &context) const
 
bool Int (Context &context, int i) const
 
bool Int64 (Context &context, int64_t i) const
 
bool Key (Context &context, const Ch *str, SizeType len, bool) const
 
bool Null (Context &context) const
 
 Schema (SchemaDocumentType *schemaDocument, const PointerType &p, const ValueType &value, const ValueType &document, AllocatorType *allocator)
 
bool StartArray (Context &context) const
 
bool StartObject (Context &context) const
 
bool String (Context &context, const Ch *str, SizeType length, bool) const
 
bool Uint (Context &context, unsigned u) const
 
bool Uint64 (Context &context, uint64_t u) const
 
 ~Schema ()
 

Private Types

typedef internal::GenericRegex< EncodingTypeRegexType
 
enum  SchemaValueType {
  kNullSchemaType, kBooleanSchemaType, kObjectSchemaType, kArraySchemaType,
  kStringSchemaType, kNumberSchemaType, kIntegerSchemaType, kTotalSchemaType
}
 

Private Member Functions

void AddType (const ValueType &type)
 
template<typename V1 , typename V2 >
void AddUniqueElement (V1 &a, const V2 &v)
 
void AssignIfExist (SchemaArray &out, SchemaDocumentType &schemaDocument, const PointerType &p, const ValueType &value, const ValueType &name, const ValueType &document)
 
bool CheckDoubleMaximum (Context &context, double d) const
 
bool CheckDoubleMinimum (Context &context, double d) const
 
bool CheckDoubleMultipleOf (Context &context, double d) const
 
bool CheckInt (Context &context, int64_t i) const
 
bool CheckUint (Context &context, uint64_t i) const
 
bool CreateParallelValidator (Context &context) const
 
template<typename ValueType >
RegexTypeCreatePattern (const ValueType &value)
 
void CreateSchemaValidators (Context &context, const SchemaArray &schemas) const
 
bool FindPropertyIndex (const ValueType &name, SizeType *outIndex) const
 

Static Private Member Functions

static void AssignIfExist (bool &out, const ValueType &value, const ValueType &name)
 
static void AssignIfExist (SizeType &out, const ValueType &value, const ValueType &name)
 
static const ValueTypeGetMember (const ValueType &value, const ValueType &name)
 
static bool IsPatternMatch (const RegexType *pattern, const Ch *str, SizeType)
 

Private Attributes

bool additionalItems_
 
const SchemaTypeadditionalItemsSchema_
 
bool additionalProperties_
 
const SchemaTypeadditionalPropertiesSchema_
 
AllocatorTypeallocator_
 
SchemaArray allOf_
 
SchemaArray anyOf_
 
uint64_tenum_
 
SizeType enumCount_
 
bool exclusiveMaximum_
 
bool exclusiveMinimum_
 
bool hasDependencies_
 
bool hasRequired_
 
bool hasSchemaDependencies_
 
const SchemaTypeitemsList_
 
const SchemaType ** itemsTuple_
 
SizeType itemsTupleCount_
 
SValue maximum_
 
SizeType maxItems_
 
SizeType maxLength_
 
SizeType maxProperties_
 
SValue minimum_
 
SizeType minItems_
 
SizeType minLength_
 
SizeType minProperties_
 
SValue multipleOf_
 
const SchemaTypenot_
 
SizeType notValidatorIndex_
 
SchemaArray oneOf_
 
RegexTypepattern_
 
PatternPropertypatternProperties_
 
SizeType patternPropertyCount_
 
Propertyproperties_
 
SizeType propertyCount_
 
unsigned type_
 
const SchemaTypetypeless_
 
bool uniqueItems_
 
SizeType validatorCount_
 

Friends

class GenericSchemaDocument< ValueType, AllocatorType >
 

Detailed Description

template<typename SchemaDocumentType>
class internal::Schema< SchemaDocumentType >

Definition at line 133 of file schema.h.

Member Typedef Documentation

template<typename SchemaDocumentType >
typedef SchemaDocumentType::AllocatorType internal::Schema< SchemaDocumentType >::AllocatorType

Definition at line 341 of file schema.h.

template<typename SchemaDocumentType >
typedef EncodingType::Ch internal::Schema< SchemaDocumentType >::Ch

Definition at line 344 of file schema.h.

template<typename SchemaDocumentType >
typedef SchemaValidationContext<SchemaDocumentType> internal::Schema< SchemaDocumentType >::Context

Definition at line 345 of file schema.h.

template<typename SchemaDocumentType >
typedef ValueType::EncodingType internal::Schema< SchemaDocumentType >::EncodingType

Definition at line 343 of file schema.h.

template<typename SchemaDocumentType >
typedef SchemaDocumentType::PointerType internal::Schema< SchemaDocumentType >::PointerType

Definition at line 342 of file schema.h.

template<typename SchemaDocumentType >
typedef internal::GenericRegex<EncodingType> internal::Schema< SchemaDocumentType >::RegexType
private

Definition at line 938 of file schema.h.

template<typename SchemaDocumentType >
typedef Schema<SchemaDocumentType> internal::Schema< SchemaDocumentType >::SchemaType

Definition at line 346 of file schema.h.

template<typename SchemaDocumentType >
typedef GenericValue<EncodingType, AllocatorType> internal::Schema< SchemaDocumentType >::SValue

Definition at line 347 of file schema.h.

template<typename SchemaDocumentType >
typedef SchemaDocumentType::ValueType internal::Schema< SchemaDocumentType >::ValueType

Definition at line 340 of file schema.h.

Member Enumeration Documentation

template<typename SchemaDocumentType >
enum internal::Schema::SchemaValueType
private
Enumerator
kNullSchemaType 
kBooleanSchemaType 
kObjectSchemaType 
kArraySchemaType 
kStringSchemaType 
kNumberSchemaType 
kIntegerSchemaType 
kTotalSchemaType 

Definition at line 926 of file schema.h.

Constructor & Destructor Documentation

template<typename SchemaDocumentType >
internal::Schema< SchemaDocumentType >::Schema ( SchemaDocumentType *  schemaDocument,
const PointerType p,
const ValueType value,
const ValueType document,
AllocatorType allocator 
)
inline

Definition at line 350 of file schema.h.

template<typename SchemaDocumentType >
internal::Schema< SchemaDocumentType >::~Schema ( )
inline

Definition at line 578 of file schema.h.

Member Function Documentation

template<typename SchemaDocumentType >
void internal::Schema< SchemaDocumentType >::AddType ( const ValueType type)
inlineprivate

Definition at line 1036 of file schema.h.

template<typename SchemaDocumentType >
template<typename V1 , typename V2 >
void internal::Schema< SchemaDocumentType >::AddUniqueElement ( V1 &  a,
const V2 &  v 
)
inlineprivate

Definition at line 954 of file schema.h.

template<typename SchemaDocumentType >
static void internal::Schema< SchemaDocumentType >::AssignIfExist ( bool &  out,
const ValueType value,
const ValueType name 
)
inlinestaticprivate

Definition at line 967 of file schema.h.

template<typename SchemaDocumentType >
static void internal::Schema< SchemaDocumentType >::AssignIfExist ( SizeType out,
const ValueType value,
const ValueType name 
)
inlinestaticprivate

Definition at line 973 of file schema.h.

template<typename SchemaDocumentType >
void internal::Schema< SchemaDocumentType >::AssignIfExist ( SchemaArray out,
SchemaDocumentType &  schemaDocument,
const PointerType p,
const ValueType value,
const ValueType name,
const ValueType document 
)
inlineprivate

Definition at line 979 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::BeginValue ( Context context) const
inline

Definition at line 599 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Bool ( Context context,
bool   
) const
inline

Definition at line 697 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::CheckDoubleMaximum ( Context context,
double  d 
) const
inlineprivate

Definition at line 1179 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::CheckDoubleMinimum ( Context context,
double  d 
) const
inlineprivate

Definition at line 1173 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::CheckDoubleMultipleOf ( Context context,
double  d 
) const
inlineprivate

Definition at line 1185 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::CheckInt ( Context context,
int64_t  i 
) const
inlineprivate

Definition at line 1096 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::CheckUint ( Context context,
uint64_t  i 
) const
inlineprivate

Definition at line 1135 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::CreateParallelValidator ( Context context) const
inlineprivate

Definition at line 1046 of file schema.h.

template<typename SchemaDocumentType >
template<typename ValueType >
RegexType* internal::Schema< SchemaDocumentType >::CreatePattern ( const ValueType value)
inlineprivate

Definition at line 996 of file schema.h.

template<typename SchemaDocumentType >
void internal::Schema< SchemaDocumentType >::CreateSchemaValidators ( Context context,
const SchemaArray schemas 
) const
inlineprivate

Definition at line 1077 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Double ( Context context,
double  d 
) const
inline

Definition at line 727 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::EndArray ( Context context,
SizeType  elementCount 
) const
inline

Definition at line 869 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::EndObject ( Context context,
SizeType  memberCount 
) const
inline

Definition at line 829 of file schema.h.

template<typename SchemaDocumentType >
RAPIDJSON_FORCEINLINE bool internal::Schema< SchemaDocumentType >::EndValue ( Context context) const
inline

Definition at line 624 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::FindPropertyIndex ( const ValueType name,
SizeType outIndex 
) const
inlineprivate

Definition at line 1083 of file schema.h.

template<typename SchemaDocumentType >
static const ValueType* internal::Schema< SchemaDocumentType >::GetMember ( const ValueType value,
const ValueType name 
)
inlinestaticprivate

Definition at line 962 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Int ( Context context,
int  i 
) const
inline

Definition at line 703 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Int64 ( Context context,
int64_t  i 
) const
inline

Definition at line 715 of file schema.h.

template<typename SchemaDocumentType >
static bool internal::Schema< SchemaDocumentType >::IsPatternMatch ( const RegexType pattern,
const Ch str,
SizeType   
)
inlinestaticprivate

Definition at line 1009 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Key ( Context context,
const Ch str,
SizeType  len,
bool   
) const
inline

Definition at line 782 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Null ( Context context) const
inline

Definition at line 691 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::StartArray ( Context context) const
inline

Definition at line 859 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::StartObject ( Context context) const
inline

Definition at line 763 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::String ( Context context,
const Ch str,
SizeType  length,
bool   
) const
inline

Definition at line 743 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Uint ( Context context,
unsigned  u 
) const
inline

Definition at line 709 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::Uint64 ( Context context,
uint64_t  u 
) const
inline

Definition at line 721 of file schema.h.

Friends And Related Function Documentation

template<typename SchemaDocumentType >
friend class GenericSchemaDocument< ValueType, AllocatorType >
friend

Definition at line 348 of file schema.h.

Member Data Documentation

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::additionalItems_
private

Definition at line 1247 of file schema.h.

template<typename SchemaDocumentType >
const SchemaType* internal::Schema< SchemaDocumentType >::additionalItemsSchema_
private

Definition at line 1241 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::additionalProperties_
private

Definition at line 1236 of file schema.h.

template<typename SchemaDocumentType >
const SchemaType* internal::Schema< SchemaDocumentType >::additionalPropertiesSchema_
private

Definition at line 1230 of file schema.h.

template<typename SchemaDocumentType >
AllocatorType* internal::Schema< SchemaDocumentType >::allocator_
private

Definition at line 1217 of file schema.h.

template<typename SchemaDocumentType >
SchemaArray internal::Schema< SchemaDocumentType >::allOf_
private

Definition at line 1221 of file schema.h.

template<typename SchemaDocumentType >
SchemaArray internal::Schema< SchemaDocumentType >::anyOf_
private

Definition at line 1222 of file schema.h.

template<typename SchemaDocumentType >
uint64_t* internal::Schema< SchemaDocumentType >::enum_
private

Definition at line 1219 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::enumCount_
private

Definition at line 1220 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::exclusiveMaximum_
private

Definition at line 1258 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::exclusiveMinimum_
private

Definition at line 1257 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::hasDependencies_
private

Definition at line 1237 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::hasRequired_
private

Definition at line 1238 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::hasSchemaDependencies_
private

Definition at line 1239 of file schema.h.

template<typename SchemaDocumentType >
const SchemaType* internal::Schema< SchemaDocumentType >::itemsList_
private

Definition at line 1242 of file schema.h.

template<typename SchemaDocumentType >
const SchemaType** internal::Schema< SchemaDocumentType >::itemsTuple_
private

Definition at line 1243 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::itemsTupleCount_
private

Definition at line 1244 of file schema.h.

template<typename SchemaDocumentType >
SValue internal::Schema< SchemaDocumentType >::maximum_
private

Definition at line 1255 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::maxItems_
private

Definition at line 1246 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::maxLength_
private

Definition at line 1252 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::maxProperties_
private

Definition at line 1235 of file schema.h.

template<typename SchemaDocumentType >
SValue internal::Schema< SchemaDocumentType >::minimum_
private

Definition at line 1254 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::minItems_
private

Definition at line 1245 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::minLength_
private

Definition at line 1251 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::minProperties_
private

Definition at line 1234 of file schema.h.

template<typename SchemaDocumentType >
SValue internal::Schema< SchemaDocumentType >::multipleOf_
private

Definition at line 1256 of file schema.h.

template<typename SchemaDocumentType >
const SchemaType* internal::Schema< SchemaDocumentType >::not_
private

Definition at line 1224 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::notValidatorIndex_
private

Definition at line 1227 of file schema.h.

template<typename SchemaDocumentType >
SchemaArray internal::Schema< SchemaDocumentType >::oneOf_
private

Definition at line 1223 of file schema.h.

template<typename SchemaDocumentType >
RegexType* internal::Schema< SchemaDocumentType >::pattern_
private

Definition at line 1250 of file schema.h.

template<typename SchemaDocumentType >
PatternProperty* internal::Schema< SchemaDocumentType >::patternProperties_
private

Definition at line 1231 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::patternPropertyCount_
private

Definition at line 1232 of file schema.h.

template<typename SchemaDocumentType >
Property* internal::Schema< SchemaDocumentType >::properties_
private

Definition at line 1229 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::propertyCount_
private

Definition at line 1233 of file schema.h.

template<typename SchemaDocumentType >
unsigned internal::Schema< SchemaDocumentType >::type_
private

Definition at line 1225 of file schema.h.

template<typename SchemaDocumentType >
const SchemaType* internal::Schema< SchemaDocumentType >::typeless_
private

Definition at line 1218 of file schema.h.

template<typename SchemaDocumentType >
bool internal::Schema< SchemaDocumentType >::uniqueItems_
private

Definition at line 1248 of file schema.h.

template<typename SchemaDocumentType >
SizeType internal::Schema< SchemaDocumentType >::validatorCount_
private

Definition at line 1226 of file schema.h.


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


choreo_rapidjson
Author(s):
autogenerated on Thu Jul 18 2019 03:59:10