1 #ifndef CPER_JSON_SCHEMA_H 2 #define CPER_JSON_SCHEMA_H 3 4 #ifdef __cplusplus 5 extern "C" { 6 #endif 7 8 #include <json.h> 9 10 #define JSON_SCHEMA_VERSION "https://json-schema.org/draft/2020-12/schema" 11 #define JSON_ERROR_MSG_MAX_LEN 512 12 13 int validate_schema(json_object *schema, char *schema_directory, 14 json_object *object, char *error_message); 15 int validate_schema_from_file(const char *schema_file, json_object *object, 16 char *error_message); 17 void validate_schema_debug_enable(); 18 void validate_schema_debug_disable(); 19 20 #ifdef __cplusplus 21 } 22 #endif 23 24 #endif 25