COSMOS core  1.0.2 (beta)
Comprehensive Open-architecture Solution for Mission Operations Systems
json11::JsonValue Class Referenceabstract

#include <json11.hpp>

Inheritance diagram for json11::JsonValue:
Collaboration diagram for json11::JsonValue:

Protected Member Functions

virtual Json::Type type () const =0
 
virtual bool equals (const JsonValue *other) const =0
 
virtual bool less (const JsonValue *other) const =0
 
virtual void dump (std::string &out) const =0
 
virtual double number_value () const
 
virtual int int_value () const
 
virtual bool bool_value () const
 
virtual const std::string & string_value () const
 
virtual const Json::arrayarray_items () const
 
virtual const Jsonoperator[] (size_t i) const
 
virtual const Json::objectobject_items () const
 
virtual const Jsonoperator[] (const std::string &key) const
 
virtual ~JsonValue ()
 

Friends

class Json
 
class JsonInt
 
class JsonDouble
 

Constructor & Destructor Documentation

virtual json11::JsonValue::~JsonValue ( )
inlineprotectedvirtual
230 {}

Member Function Documentation

virtual void json11::JsonValue::dump ( std::string &  out) const
protectedpure virtual
double json11::JsonValue::number_value ( ) const
protectedvirtual

Reimplemented in json11::JsonInt, and json11::JsonDouble.

289 { return 0; }
int json11::JsonValue::int_value ( ) const
protectedvirtual

Reimplemented in json11::JsonInt, and json11::JsonDouble.

290 { return 0; }
bool json11::JsonValue::bool_value ( ) const
protectedvirtual

Reimplemented in json11::JsonBoolean.

291 { return false; }
const string & json11::JsonValue::string_value ( ) const
protectedvirtual

Reimplemented in json11::JsonString.

292 { return statics().empty_string; }
const string empty_string
Definition: json11.cpp:232
static const Statics & statics()
Definition: json11.cpp:238
const vector< Json > & json11::JsonValue::array_items ( ) const
protectedvirtual

Reimplemented in json11::JsonArray.

293 { return statics().empty_vector; }
const vector< Json > empty_vector
Definition: json11.cpp:233
static const Statics & statics()
Definition: json11.cpp:238
const Json & json11::JsonValue::operator[] ( size_t  i) const
protectedvirtual

Reimplemented in json11::JsonArray.

295 { return static_null(); }
static const Json & static_null()
Definition: json11.cpp:243
const map< string, Json > & json11::JsonValue::object_items ( ) const
protectedvirtual

Reimplemented in json11::JsonObject.

294 { return statics().empty_map; }
const map< string, Json > empty_map
Definition: json11.cpp:234
static const Statics & statics()
Definition: json11.cpp:238
virtual const Json& json11::JsonValue::operator[] ( const std::string &  key) const
protectedvirtual

Friends And Related Function Documentation

friend class Json
friend
friend class JsonInt
friend
friend class JsonDouble
friend

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