MQTTSuite
Loading...
Searching...
No Matches
anonymous_namespace{json-validator.cpp}::first_error_handler Class Reference
Inheritance diagram for anonymous_namespace{json-validator.cpp}::first_error_handler:
Collaboration diagram for anonymous_namespace{json-validator.cpp}::first_error_handler:

Public Member Functions

void error (const json::json_pointer &ptr, const json &instance, const std::string &message) override
 operator bool () const
void error (const json::json_pointer &ptr, const json &instance, const std::string &message) override
 operator bool () const
Public Member Functions inherited from nlohmann::json_schema::error_handler
virtual ~error_handler ()

Public Attributes

bool error_ {false}
json::json_pointer ptr_
json instance_
std::string message_

Detailed Description

Definition at line 374 of file json-validator.cpp.

Member Function Documentation

◆ error() [1/2]

void anonymous_namespace{json-validator.cpp}::first_error_handler::error ( const json::json_pointer & ptr,
const json & instance,
const std::string & message )
inlineoverridevirtual

◆ error() [2/2]

void anonymous_namespace{json-validator.cpp}::first_error_handler::error ( const json::json_pointer & ptr,
const json & instance,
const std::string & message )
inlineoverridevirtual

Implements nlohmann::json_schema::error_handler.

Definition at line 382 of file json-validator.cpp.

383 {
384 if (*this)
385 return;
386 error_ = true;
387 ptr_ = ptr;
389 message_ = message;
390 }

◆ operator bool() [1/2]

anonymous_namespace{json-validator.cpp}::first_error_handler::operator bool ( ) const
inline

Definition at line 392 of file json-validator.cpp.

392{ return error_; }

References error_.

◆ operator bool() [2/2]

anonymous_namespace{json-validator.cpp}::first_error_handler::operator bool ( ) const
inline

Definition at line 392 of file json-validator.cpp.

392{ return error_; }

Member Data Documentation

◆ error_

bool anonymous_namespace{json-validator.cpp}::first_error_handler::error_ {false}

Definition at line 377 of file json-validator.cpp.

377{false};

Referenced by error(), and operator bool().

◆ instance_

json anonymous_namespace{json-validator.cpp}::first_error_handler::instance_

Definition at line 379 of file json-validator.cpp.

Referenced by error().

◆ message_

std::string anonymous_namespace{json-validator.cpp}::first_error_handler::message_

◆ ptr_

json::json_pointer anonymous_namespace{json-validator.cpp}::first_error_handler::ptr_

Definition at line 378 of file json-validator.cpp.

Referenced by error().


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