|
| Value () noexcept |
| Constructs a Value that holds a Null.
|
|
| Value (Value &&) |
|
| Value (const Value &) |
|
Value & | operator= (Value &&) |
|
Value & | operator= (const Value &) |
|
template<class T > |
Value & | operator= (T &&) && |
|
| Value (Value &&other, std::string path_prefix) |
| Copies other , appending path_prefix to the stored path
|
|
Value | operator[] (std::string_view key) const |
| Access member by key for read.
|
|
Value | operator[] (std::size_t index) const |
| Access array member by index for read.
|
|
const_iterator | begin () const |
| Returns an iterator to the beginning of the held array or map.
|
|
const_iterator | end () const |
| Returns an iterator to the end of the held array or map.
|
|
bool | IsEmpty () const |
| Returns whether the array or object is empty.
|
|
std::size_t | GetSize () const |
| Returns array size or object members count.
|
|
bool | operator== (const Value &other) const |
| Compares values.
|
|
bool | operator!= (const Value &other) const |
|
bool | IsMissing () const |
| Returns true if *this holds nothing. When IsMissing() returns true any attempt to get the actual value or iterate over *this will throw MemberMissingException.
|
|
bool | IsNull () const noexcept |
| Returns true if *this holds a Null (Type::kNull).
|
|
bool | IsBool () const noexcept |
| Returns true if *this is convertible to bool.
|
|
bool | IsInt () const noexcept |
| Returns true if *this is convertible to int.
|
|
bool | IsInt64 () const noexcept |
| Returns true if *this is convertible to int64_t.
|
|
bool | IsUInt64 () const noexcept |
| Returns true if *this is convertible to uint64_t.
|
|
bool | IsDouble () const noexcept |
| Returns true if *this is convertible to double.
|
|
bool | IsString () const noexcept |
| Returns true if *this is convertible to std::string.
|
|
bool | IsArray () const noexcept |
| Returns true if *this is an array (Type::kArray).
|
|
bool | IsObject () const noexcept |
| Returns true if *this is a map (Type::kObject).
|
|
template<typename T > |
T | As () const |
| Returns value of *this converted to T.
|
|
template<typename T , typename First , typename... Rest> |
T | As (First &&default_arg, Rest &&... more_default_args) const |
| Returns value of *this converted to T or T(args) if this->IsMissing().
|
|
template<typename T > |
T | As (DefaultConstructed) const |
| Returns value of *this converted to T or T() if this->IsMissing().
|
|
bool | HasMember (std::string_view key) const |
| Returns true if *this holds a key .
|
|
std::string | GetPath () const |
| Returns full path to this value.
|
|
int | GetColumn () const |
| Returns 0-based column number of this Value in the original document. Returns -1 if this->IsMissing() . If Value was created using formats::yaml::ValueBuilder, returns 0 .
|
|
int | GetLine () const |
| Returns 0-based line number of this Value in the original document. Returns -1 if this->IsMissing() . If Value was created using formats::yaml::ValueBuilder, returns 0 .
|
|
Value | Clone () const |
| Returns new value that is an exact copy if the existing one but references different memory (a deep copy of a *this). The returned value is a root value with path '/'.
|
|
void | CheckNotMissing () const |
|
void | CheckArray () const |
|
void | CheckArrayOrNull () const |
|
void | CheckObjectOrNull () const |
|
void | CheckObject () const |
|
void | CheckString () const |
|
void | CheckObjectOrArrayOrNull () const |
|
void | CheckInBounds (std::size_t index) const |
|
bool | IsRoot () const noexcept |
| Returns true if *this is a first (root) value.
|
|
bool | DebugIsReferencingSameMemory (const Value &other) const |
| Returns true if *this and other reference the value by the same pointer.
|
|
template<> |
bool | As () const |
|
template<> |
int64_t | As () const |
|
template<> |
uint64_t | As () const |
|
template<> |
double | As () const |
|