Open Lighting Architecture  Latest Git
Public Member Functions | List of all members
ola::web::JsonString Class Reference

Detailed Description

A string value.

Inheritance diagram for ola::web::JsonString:
Inheritance graph
[legend]
Collaboration diagram for ola::web::JsonString:
Collaboration graph
[legend]

Public Member Functions

 JsonString (const std::string &value)
 Create a new JsonString. More...
 
bool operator== (const JsonValue &other) const
 Equality operator. More...
 
const std::string & Value () const
 Return the string value.
 
void Accept (JsonValueVisitorInterface *visitor)
 The Accept method for the visitor pattern. More...
 
void Accept (JsonValueConstVisitorInterface *visitor) const
 The Accept (const) method for the visitor pattern. More...
 
JsonValueClone () const
 Make a copy of this JsonValue.
 
- Public Member Functions inherited from ola::web::JsonValue
virtual JsonValueLookupElement (const JsonPointer &pointer)
 Locate the JsonValue referred to by the JSON Pointer.
 
virtual bool operator!= (const JsonValue &other) const
 Not-equals operator.
 

Constructor & Destructor Documentation

◆ JsonString()

ola::web::JsonString::JsonString ( const std::string &  value)
inlineexplicit

Create a new JsonString.

Parameters
valuethe string to use.

Member Function Documentation

◆ Accept() [1/2]

void ola::web::JsonString::Accept ( JsonValueVisitorInterface visitor)
inlinevirtual

The Accept method for the visitor pattern.

This can be used to traverse the Json Tree in a type-safe manner.

Implements ola::web::JsonValue.

◆ Accept() [2/2]

void ola::web::JsonString::Accept ( JsonValueConstVisitorInterface visitor) const
inlinevirtual

The Accept (const) method for the visitor pattern.

This can be used to traverse the Json Tree in a type-safe manner.

Implements ola::web::JsonValue.

◆ operator==()

bool ola::web::JsonString::operator== ( const JsonValue other) const
inlinevirtual

Equality operator.

This implements equality as defined in section 3.6 of the JSON Schema Core document.

Implements ola::web::JsonValue.


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