Electroneum
Loading...
Searching...
No Matches
GenericObject< Const, ValueT > Class Template Reference

Helper class for accessing Value of object type. More...

#include <document.h>

Public Types

typedef GenericObject< true, ValueT > ConstObject
typedef GenericObject< false, ValueT > Object
typedef ValueT PlainType
typedef internal::MaybeAddConst< Const, PlainType >::Type ValueType
typedef GenericMemberIterator< Const, typename ValueT::EncodingType, typename ValueT::AllocatorType > MemberIterator
typedef GenericMemberIterator< true, typename ValueT::EncodingType, typename ValueT::AllocatorType > ConstMemberIterator
typedef ValueType::AllocatorType AllocatorType
typedef ValueType::StringRefType StringRefType
typedef ValueType::EncodingType EncodingType
typedef ValueType::Ch Ch

Public Member Functions

 GenericObject (const GenericObject &rhs)
GenericObjectoperator= (const GenericObject &rhs)
 ~GenericObject ()
SizeType MemberCount () const
SizeType MemberCapacity () const
bool ObjectEmpty () const
template<typename T>
ValueTypeoperator[] (T *name) const
template<typename SourceAllocator>
ValueTypeoperator[] (const GenericValue< EncodingType, SourceAllocator > &name) const
MemberIterator MemberBegin () const
MemberIterator MemberEnd () const
GenericObject MemberReserve (SizeType newCapacity, AllocatorType &allocator) const
bool HasMember (const Ch *name) const
template<typename SourceAllocator>
bool HasMember (const GenericValue< EncodingType, SourceAllocator > &name) const
MemberIterator FindMember (const Ch *name) const
template<typename SourceAllocator>
MemberIterator FindMember (const GenericValue< EncodingType, SourceAllocator > &name) const
GenericObject AddMember (ValueType &name, ValueType &value, AllocatorType &allocator) const
GenericObject AddMember (ValueType &name, StringRefType value, AllocatorType &allocator) const
template<typename T>
 RAPIDJSON_DISABLEIF_RETURN ((internal::OrExpr< internal::IsPointer< T >, internal::IsGenericValue< T > >),(ValueType &)) AddMember(ValueType &name
GenericObject AddMember (StringRefType name, ValueType &value, AllocatorType &allocator) const
GenericObject AddMember (StringRefType name, StringRefType value, AllocatorType &allocator) const
template<typename T>
 RAPIDJSON_DISABLEIF_RETURN ((internal::OrExpr< internal::IsPointer< T >, internal::IsGenericValue< T > >),(GenericObject)) AddMember(StringRefType name
void RemoveAllMembers ()
bool RemoveMember (const Ch *name) const
template<typename SourceAllocator>
bool RemoveMember (const GenericValue< EncodingType, SourceAllocator > &name) const
MemberIterator RemoveMember (MemberIterator m) const
MemberIterator EraseMember (ConstMemberIterator pos) const
MemberIterator EraseMember (ConstMemberIterator first, ConstMemberIterator last) const
bool EraseMember (const Ch *name) const
template<typename SourceAllocator>
bool EraseMember (const GenericValue< EncodingType, SourceAllocator > &name) const

Public Attributes

T value
T AllocatorType &allocator const { value_.AddMember(name, value, allocator)
return * this

Friends

template<typename, typename>
class GenericValue

Detailed Description

template<bool Const, typename ValueT>
class GenericObject< Const, ValueT >

Helper class for accessing Value of object type.

Instance of this helper class is obtained by GenericValue::GetObject(). In addition to all APIs for array type, it provides range-based for loop if RAPIDJSON_HAS_CXX11_RANGE_FOR=1.

Definition at line 2573 of file document.h.

Member Typedef Documentation

◆ AllocatorType

template<bool Const, typename ValueT>
typedef ValueType::AllocatorType GenericObject< Const, ValueT >::AllocatorType

Definition at line 2581 of file document.h.

◆ Ch

template<bool Const, typename ValueT>
typedef ValueType::Ch GenericObject< Const, ValueT >::Ch

Definition at line 2584 of file document.h.

◆ ConstMemberIterator

template<bool Const, typename ValueT>
typedef GenericMemberIterator<true, typename ValueT::EncodingType, typename ValueT::AllocatorType> GenericObject< Const, ValueT >::ConstMemberIterator

Definition at line 2580 of file document.h.

◆ ConstObject

template<bool Const, typename ValueT>
typedef GenericObject<true, ValueT> GenericObject< Const, ValueT >::ConstObject

Definition at line 2575 of file document.h.

◆ EncodingType

template<bool Const, typename ValueT>
typedef ValueType::EncodingType GenericObject< Const, ValueT >::EncodingType

Definition at line 2583 of file document.h.

◆ MemberIterator

template<bool Const, typename ValueT>
typedef GenericMemberIterator<Const, typename ValueT::EncodingType, typename ValueT::AllocatorType> GenericObject< Const, ValueT >::MemberIterator

Definition at line 2579 of file document.h.

◆ Object

template<bool Const, typename ValueT>
typedef GenericObject<false, ValueT> GenericObject< Const, ValueT >::Object

Definition at line 2576 of file document.h.

◆ PlainType

template<bool Const, typename ValueT>
typedef ValueT GenericObject< Const, ValueT >::PlainType

Definition at line 2577 of file document.h.

◆ StringRefType

template<bool Const, typename ValueT>
typedef ValueType::StringRefType GenericObject< Const, ValueT >::StringRefType

Definition at line 2582 of file document.h.

◆ ValueType

template<bool Const, typename ValueT>
typedef internal::MaybeAddConst<Const,PlainType>::Type GenericObject< Const, ValueT >::ValueType

Definition at line 2578 of file document.h.

Constructor & Destructor Documentation

◆ GenericObject()

template<bool Const, typename ValueT>
GenericObject< Const, ValueT >::GenericObject ( const GenericObject< Const, ValueT > & rhs)
inline

Definition at line 2589 of file document.h.

2589: value_(rhs.value_) {}
Helper class for accessing Value of object type.
Definition document.h:2573

◆ ~GenericObject()

template<bool Const, typename ValueT>
GenericObject< Const, ValueT >::~GenericObject ( )
inline

Definition at line 2591 of file document.h.

2591{}

Member Function Documentation

◆ AddMember() [1/4]

template<bool Const, typename ValueT>
GenericObject GenericObject< Const, ValueT >::AddMember ( StringRefType name,
StringRefType value,
AllocatorType & allocator ) const
inline

Definition at line 2627 of file document.h.

2627{ value_.AddMember(name, value, allocator); return *this; }

◆ AddMember() [2/4]

template<bool Const, typename ValueT>
GenericObject GenericObject< Const, ValueT >::AddMember ( StringRefType name,
ValueType & value,
AllocatorType & allocator ) const
inline

Definition at line 2626 of file document.h.

2626{ value_.AddMember(name, value, allocator); return *this; }

◆ AddMember() [3/4]

template<bool Const, typename ValueT>
GenericObject GenericObject< Const, ValueT >::AddMember ( ValueType & name,
StringRefType value,
AllocatorType & allocator ) const
inline

Definition at line 2615 of file document.h.

2615{ value_.AddMember(name, value, allocator); return *this; }

◆ AddMember() [4/4]

template<bool Const, typename ValueT>
GenericObject GenericObject< Const, ValueT >::AddMember ( ValueType & name,
ValueType & value,
AllocatorType & allocator ) const
inline

Definition at line 2614 of file document.h.

2614{ value_.AddMember(name, value, allocator); return *this; }
Here is the caller graph for this function:

◆ EraseMember() [1/4]

template<bool Const, typename ValueT>
bool GenericObject< Const, ValueT >::EraseMember ( const Ch * name) const
inline

Definition at line 2638 of file document.h.

2638{ return value_.EraseMember(name); }

◆ EraseMember() [2/4]

template<bool Const, typename ValueT>
template<typename SourceAllocator>
bool GenericObject< Const, ValueT >::EraseMember ( const GenericValue< EncodingType, SourceAllocator > & name) const
inline

Definition at line 2642 of file document.h.

2642{ return value_.EraseMember(name); }

◆ EraseMember() [3/4]

template<bool Const, typename ValueT>
MemberIterator GenericObject< Const, ValueT >::EraseMember ( ConstMemberIterator first,
ConstMemberIterator last ) const
inline

Definition at line 2637 of file document.h.

2637{ return value_.EraseMember(first, last); }

◆ EraseMember() [4/4]

template<bool Const, typename ValueT>
MemberIterator GenericObject< Const, ValueT >::EraseMember ( ConstMemberIterator pos) const
inline

Definition at line 2636 of file document.h.

2636{ return value_.EraseMember(pos); }

◆ FindMember() [1/2]

template<bool Const, typename ValueT>
MemberIterator GenericObject< Const, ValueT >::FindMember ( const Ch * name) const
inline

Definition at line 2609 of file document.h.

2609{ return value_.FindMember(name); }

◆ FindMember() [2/2]

template<bool Const, typename ValueT>
template<typename SourceAllocator>
MemberIterator GenericObject< Const, ValueT >::FindMember ( const GenericValue< EncodingType, SourceAllocator > & name) const
inline

Definition at line 2610 of file document.h.

2610{ return value_.FindMember(name); }

◆ HasMember() [1/2]

template<bool Const, typename ValueT>
bool GenericObject< Const, ValueT >::HasMember ( const Ch * name) const
inline

Definition at line 2604 of file document.h.

2604{ return value_.HasMember(name); }

◆ HasMember() [2/2]

template<bool Const, typename ValueT>
template<typename SourceAllocator>
bool GenericObject< Const, ValueT >::HasMember ( const GenericValue< EncodingType, SourceAllocator > & name) const
inline

Definition at line 2608 of file document.h.

2608{ return value_.HasMember(name); }

◆ MemberBegin()

template<bool Const, typename ValueT>
MemberIterator GenericObject< Const, ValueT >::MemberBegin ( ) const
inline

Definition at line 2601 of file document.h.

2601{ return value_.MemberBegin(); }

◆ MemberCapacity()

template<bool Const, typename ValueT>
SizeType GenericObject< Const, ValueT >::MemberCapacity ( ) const
inline

Definition at line 2594 of file document.h.

2594{ return value_.MemberCapacity(); }

◆ MemberCount()

template<bool Const, typename ValueT>
SizeType GenericObject< Const, ValueT >::MemberCount ( ) const
inline

Definition at line 2593 of file document.h.

2593{ return value_.MemberCount(); }
Here is the caller graph for this function:

◆ MemberEnd()

template<bool Const, typename ValueT>
MemberIterator GenericObject< Const, ValueT >::MemberEnd ( ) const
inline

Definition at line 2602 of file document.h.

2602{ return value_.MemberEnd(); }

◆ MemberReserve()

template<bool Const, typename ValueT>
GenericObject GenericObject< Const, ValueT >::MemberReserve ( SizeType newCapacity,
AllocatorType & allocator ) const
inline

Definition at line 2603 of file document.h.

2603{ value_.MemberReserve(newCapacity, allocator); return *this; }
Here is the caller graph for this function:

◆ ObjectEmpty()

template<bool Const, typename ValueT>
bool GenericObject< Const, ValueT >::ObjectEmpty ( ) const
inline

Definition at line 2595 of file document.h.

2595{ return value_.ObjectEmpty(); }

◆ operator=()

template<bool Const, typename ValueT>
GenericObject & GenericObject< Const, ValueT >::operator= ( const GenericObject< Const, ValueT > & rhs)
inline

Definition at line 2590 of file document.h.

2590{ value_ = rhs.value_; return *this; }

◆ operator[]() [1/2]

template<bool Const, typename ValueT>
template<typename SourceAllocator>
ValueType & GenericObject< Const, ValueT >::operator[] ( const GenericValue< EncodingType, SourceAllocator > & name) const
inline

Definition at line 2597 of file document.h.

2597{ return value_[name]; }

◆ operator[]() [2/2]

template<bool Const, typename ValueT>
template<typename T>
ValueType & GenericObject< Const, ValueT >::operator[] ( T * name) const
inline

Definition at line 2596 of file document.h.

2596{ return value_[name]; }

◆ RAPIDJSON_DISABLEIF_RETURN() [1/2]

template<bool Const, typename ValueT>
template<typename T>
GenericObject< Const, ValueT >::RAPIDJSON_DISABLEIF_RETURN ( (internal::OrExpr< internal::IsPointer< T >, internal::IsGenericValue< T > >) ,
(GenericObject< Const, ValueT >)  )

◆ RAPIDJSON_DISABLEIF_RETURN() [2/2]

template<bool Const, typename ValueT>
template<typename T>
GenericObject< Const, ValueT >::RAPIDJSON_DISABLEIF_RETURN ( (internal::OrExpr< internal::IsPointer< T >, internal::IsGenericValue< T > >) ,
(ValueType &)  ) &

◆ RemoveAllMembers()

template<bool Const, typename ValueT>
void GenericObject< Const, ValueT >::RemoveAllMembers ( )
inline

Definition at line 2629 of file document.h.

2629{ value_.RemoveAllMembers(); }

◆ RemoveMember() [1/3]

template<bool Const, typename ValueT>
bool GenericObject< Const, ValueT >::RemoveMember ( const Ch * name) const
inline

Definition at line 2630 of file document.h.

2630{ return value_.RemoveMember(name); }

◆ RemoveMember() [2/3]

template<bool Const, typename ValueT>
template<typename SourceAllocator>
bool GenericObject< Const, ValueT >::RemoveMember ( const GenericValue< EncodingType, SourceAllocator > & name) const
inline

Definition at line 2634 of file document.h.

2634{ return value_.RemoveMember(name); }

◆ RemoveMember() [3/3]

template<bool Const, typename ValueT>
MemberIterator GenericObject< Const, ValueT >::RemoveMember ( MemberIterator m) const
inline

Definition at line 2635 of file document.h.

2635{ return value_.RemoveMember(m); }

◆ GenericValue

template<bool Const, typename ValueT>
template<typename, typename>
friend class GenericValue
friend

Definition at line 2587 of file document.h.

Member Data Documentation

◆ const

template<bool Const, typename ValueT>
T AllocatorType &allocator GenericObject< Const, ValueT >::const { value_.AddMember(name, value, allocator)

Definition at line 2619 of file document.h.

◆ this

template<bool Const, typename ValueT>
return * GenericObject< Const, ValueT >::this

Definition at line 2619 of file document.h.

◆ value

template<bool Const, typename ValueT>
T GenericObject< Const, ValueT >::value

Definition at line 2619 of file document.h.


The documentation for this class was generated from the following file:
  • /home/abuild/rpmbuild/BUILD/electroneum-5.1.3.1-build/electroneum-5.1.3.1/external/rapidjson/include/rapidjson/document.h