Classes | Typedefs | Enumerations | Variables
pointer.h File Reference
#include "document.h"
#include "internal/itoa.h"
Include dependency graph for pointer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  GenericPointer< ValueType, Allocator >
 Represents a JSON Pointer. Use Pointer for UTF8 encoding and default allocator. More...
 
class  GenericPointer< ValueType, Allocator >::PercentEncodeStream< OutputStream >
 A helper stream to encode character (UTF-8 code unit) into percent-encoded sequence. More...
 
struct  GenericPointer< ValueType, Allocator >::Token
 A token is the basic units of internal representation. More...
 

Typedefs

typedef GenericPointer< ValuePointer
 GenericPointer for Value (UTF-8, default allocator). More...
 

Enumerations

enum  PointerParseErrorCode {
  kPointerParseErrorNone = 0, kPointerParseErrorTokenMustBeginWithSolidus, kPointerParseErrorInvalidEscape, kPointerParseErrorInvalidPercentEncoding,
  kPointerParseErrorCharacterMustPercentEncode
}
 Error code of parsing. More...
 

Variables

static RAPIDJSON_NAMESPACE_BEGIN const SizeType kPointerInvalidIndex = ~SizeType(0)
 Represents an invalid index in GenericPointer::Token. More...
 

Helper functions for GenericPointer

const GenericPointer< typename T::ValueType > & pointer
 
const GenericPointer< typename T::ValueType > T2 defaultValue
 
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
 
const CharType(& source )[N]
 
const GenericPointer< typename T::ValueType > T2 value
 
template<typename T >
T::ValueType & CreateValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N>
T::ValueType & CreateValueByPointer (T &root, const CharType(&source)[N], typename T::AllocatorType &a)
 
template<typename DocumentType >
DocumentType::ValueType & CreateValueByPointer (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer)
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & CreateValueByPointer (DocumentType &document, const CharType(&source)[N])
 
template<typename T >
T::ValueType * GetValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer, size_t *unresolvedTokenIndex=0)
 
template<typename T >
const T::ValueType * GetValueByPointer (const T &root, const GenericPointer< typename T::ValueType > &pointer, size_t *unresolvedTokenIndex=0)
 
template<typename T , typename CharType , size_t N>
T::ValueType * GetValueByPointer (T &root, const CharType(&source)[N], size_t *unresolvedTokenIndex=0)
 
template<typename T , typename CharType , size_t N>
const T::ValueType * GetValueByPointer (const T &root, const CharType(&source)[N], size_t *unresolvedTokenIndex=0)
 
template<typename T >
T::ValueType & GetValueByPointerWithDefault (T &root, const GenericPointer< typename T::ValueType > &pointer, const typename T::ValueType &defaultValue, typename T::AllocatorType &a)
 
template<typename T >
T::ValueType & GetValueByPointerWithDefault (T &root, const GenericPointer< typename T::ValueType > &pointer, const typename T::Ch *defaultValue, typename T::AllocatorType &a)
 
template<typename T , typename T2 >
 RAPIDJSON_DISABLEIF_RETURN ((internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >),(typename T::ValueType &)) GetValueByPointerWithDefault(T &root
 
template<typename T , typename CharType , size_t N>
T::ValueType & GetValueByPointerWithDefault (T &root, const CharType(&source)[N], const typename T::ValueType &defaultValue, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N>
T::ValueType & GetValueByPointerWithDefault (T &root, const CharType(&source)[N], const typename T::Ch *defaultValue, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N, typename T2 >
 RAPIDJSON_DISABLEIF_RETURN ((internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >),(typename T::ValueType &)) GetValueByPointerWithDefault(T &root
 
template<typename DocumentType >
DocumentType::ValueType & GetValueByPointerWithDefault (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer, const typename DocumentType::ValueType &defaultValue)
 
template<typename DocumentType >
DocumentType::ValueType & GetValueByPointerWithDefault (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer, const typename DocumentType::Ch *defaultValue)
 
template<typename DocumentType , typename T2 >
 RAPIDJSON_DISABLEIF_RETURN ((internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >),(typename DocumentType::ValueType &)) GetValueByPointerWithDefault(DocumentType &document
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & GetValueByPointerWithDefault (DocumentType &document, const CharType(&source)[N], const typename DocumentType::ValueType &defaultValue)
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & GetValueByPointerWithDefault (DocumentType &document, const CharType(&source)[N], const typename DocumentType::Ch *defaultValue)
 
template<typename DocumentType , typename CharType , size_t N, typename T2 >
 RAPIDJSON_DISABLEIF_RETURN ((internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >),(typename DocumentType::ValueType &)) GetValueByPointerWithDefault(DocumentType &document
 
template<typename T >
T::ValueType & SetValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer, typename T::ValueType &value, typename T::AllocatorType &a)
 
template<typename T >
T::ValueType & SetValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer, const typename T::ValueType &value, typename T::AllocatorType &a)
 
template<typename T >
T::ValueType & SetValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer, const typename T::Ch *value, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N>
T::ValueType & SetValueByPointer (T &root, const CharType(&source)[N], typename T::ValueType &value, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N>
T::ValueType & SetValueByPointer (T &root, const CharType(&source)[N], const typename T::ValueType &value, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N>
T::ValueType & SetValueByPointer (T &root, const CharType(&source)[N], const typename T::Ch *value, typename T::AllocatorType &a)
 
template<typename DocumentType >
DocumentType::ValueType & SetValueByPointer (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer, typename DocumentType::ValueType &value)
 
template<typename DocumentType >
DocumentType::ValueType & SetValueByPointer (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer, const typename DocumentType::ValueType &value)
 
template<typename DocumentType >
DocumentType::ValueType & SetValueByPointer (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer, const typename DocumentType::Ch *value)
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & SetValueByPointer (DocumentType &document, const CharType(&source)[N], typename DocumentType::ValueType &value)
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & SetValueByPointer (DocumentType &document, const CharType(&source)[N], const typename DocumentType::ValueType &value)
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & SetValueByPointer (DocumentType &document, const CharType(&source)[N], const typename DocumentType::Ch *value)
 
template<typename T >
T::ValueType & swapValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer, typename T::ValueType &value, typename T::AllocatorType &a)
 
template<typename T , typename CharType , size_t N>
T::ValueType & swapValueByPointer (T &root, const CharType(&source)[N], typename T::ValueType &value, typename T::AllocatorType &a)
 
template<typename DocumentType >
DocumentType::ValueType & swapValueByPointer (DocumentType &document, const GenericPointer< typename DocumentType::ValueType > &pointer, typename DocumentType::ValueType &value)
 
template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType & swapValueByPointer (DocumentType &document, const CharType(&source)[N], typename DocumentType::ValueType &value)
 
template<typename T >
bool EraseValueByPointer (T &root, const GenericPointer< typename T::ValueType > &pointer)
 
template<typename T , typename CharType , size_t N>
bool EraseValueByPointer (T &root, const CharType(&source)[N])
 

Typedef Documentation

GenericPointer for Value (UTF-8, default allocator).

Definition at line 1326 of file pointer.h.

Function Documentation

template<typename T >
T::ValueType& CreateValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
typename T::AllocatorType &  a 
)

Definition at line 1334 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& CreateValueByPointer ( T &  root,
const CharType(&)  source[N],
typename T::AllocatorType &  a 
)

Definition at line 1341 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& CreateValueByPointer ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer 
)

Definition at line 1349 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& CreateValueByPointer ( DocumentType &  document,
const CharType(&)  source[N] 
)

Definition at line 1356 of file pointer.h.

template<typename T >
bool EraseValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer 
)

Definition at line 1722 of file pointer.h.

template<typename T , typename CharType , size_t N>
bool EraseValueByPointer ( T &  root,
const CharType(&)  source[N] 
)

Definition at line 1728 of file pointer.h.

template<typename T >
T::ValueType* GetValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
size_t *  unresolvedTokenIndex = 0 
)

Definition at line 1364 of file pointer.h.

template<typename T >
const T::ValueType* GetValueByPointer ( const T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
size_t *  unresolvedTokenIndex = 0 
)

Definition at line 1371 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType* GetValueByPointer ( T &  root,
const CharType(&)  source[N],
size_t *  unresolvedTokenIndex = 0 
)

Definition at line 1378 of file pointer.h.

template<typename T , typename CharType , size_t N>
const T::ValueType* GetValueByPointer ( const T &  root,
const CharType(&)  source[N],
size_t *  unresolvedTokenIndex = 0 
)

Definition at line 1384 of file pointer.h.

template<typename T >
T::ValueType& GetValueByPointerWithDefault ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
const typename T::ValueType &  defaultValue,
typename T::AllocatorType &  a 
)

Definition at line 1393 of file pointer.h.

template<typename T >
T::ValueType& GetValueByPointerWithDefault ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
const typename T::Ch *  defaultValue,
typename T::AllocatorType &  a 
)

Definition at line 1401 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& GetValueByPointerWithDefault ( T &  root,
const CharType(&)  source[N],
const typename T::ValueType &  defaultValue,
typename T::AllocatorType &  a 
)

Definition at line 1427 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& GetValueByPointerWithDefault ( T &  root,
const CharType(&)  source[N],
const typename T::Ch *  defaultValue,
typename T::AllocatorType &  a 
)

Definition at line 1435 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& GetValueByPointerWithDefault ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer,
const typename DocumentType::ValueType &  defaultValue 
)

Definition at line 1463 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& GetValueByPointerWithDefault ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer,
const typename DocumentType::Ch *  defaultValue 
)

Definition at line 1471 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& GetValueByPointerWithDefault ( DocumentType &  document,
const CharType(&)  source[N],
const typename DocumentType::ValueType &  defaultValue 
)

Definition at line 1497 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& GetValueByPointerWithDefault ( DocumentType &  document,
const CharType(&)  source[N],
const typename DocumentType::Ch *  defaultValue 
)

Definition at line 1504 of file pointer.h.

template<typename T , typename T2 >
RAPIDJSON_DISABLEIF_RETURN ( (internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >)  ,
(typename T::ValueType &)   
)
template<typename T , typename CharType , size_t N, typename T2 >
RAPIDJSON_DISABLEIF_RETURN ( (internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >)  ,
(typename T::ValueType &)   
)
template<typename DocumentType , typename T2 >
RAPIDJSON_DISABLEIF_RETURN ( (internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >)  ,
(typename DocumentType::ValueType &)   
)
template<typename DocumentType , typename CharType , size_t N, typename T2 >
RAPIDJSON_DISABLEIF_RETURN ( (internal::OrExpr< internal::IsPointer< T2 >, internal::IsGenericValue< T2 > >)  ,
(typename DocumentType::ValueType &)   
)
template<typename T >
T::ValueType& SetValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
typename T::ValueType &  value,
typename T::AllocatorType &  a 
)

Definition at line 1531 of file pointer.h.

template<typename T >
T::ValueType& SetValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
const typename T::ValueType &  value,
typename T::AllocatorType &  a 
)

Definition at line 1538 of file pointer.h.

template<typename T >
T::ValueType& SetValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
const typename T::Ch *  value,
typename T::AllocatorType &  a 
)

Definition at line 1545 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& SetValueByPointer ( T &  root,
const CharType(&)  source[N],
typename T::ValueType &  value,
typename T::AllocatorType &  a 
)

Definition at line 1569 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& SetValueByPointer ( T &  root,
const CharType(&)  source[N],
const typename T::ValueType &  value,
typename T::AllocatorType &  a 
)

Definition at line 1576 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& SetValueByPointer ( T &  root,
const CharType(&)  source[N],
const typename T::Ch *  value,
typename T::AllocatorType &  a 
)

Definition at line 1583 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& SetValueByPointer ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer,
typename DocumentType::ValueType &  value 
)

Definition at line 1609 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& SetValueByPointer ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer,
const typename DocumentType::ValueType &  value 
)

Definition at line 1617 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& SetValueByPointer ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer,
const typename DocumentType::Ch *  value 
)

Definition at line 1625 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& SetValueByPointer ( DocumentType &  document,
const CharType(&)  source[N],
typename DocumentType::ValueType &  value 
)

Definition at line 1651 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& SetValueByPointer ( DocumentType &  document,
const CharType(&)  source[N],
const typename DocumentType::ValueType &  value 
)

Definition at line 1658 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& SetValueByPointer ( DocumentType &  document,
const CharType(&)  source[N],
const typename DocumentType::Ch *  value 
)

Definition at line 1665 of file pointer.h.

template<typename T >
T::ValueType& swapValueByPointer ( T &  root,
const GenericPointer< typename T::ValueType > &  pointer,
typename T::ValueType &  value,
typename T::AllocatorType &  a 
)

Definition at line 1691 of file pointer.h.

template<typename T , typename CharType , size_t N>
T::ValueType& swapValueByPointer ( T &  root,
const CharType(&)  source[N],
typename T::ValueType &  value,
typename T::AllocatorType &  a 
)

Definition at line 1698 of file pointer.h.

template<typename DocumentType >
DocumentType::ValueType& swapValueByPointer ( DocumentType &  document,
const GenericPointer< typename DocumentType::ValueType > &  pointer,
typename DocumentType::ValueType &  value 
)

Definition at line 1705 of file pointer.h.

template<typename DocumentType , typename CharType , size_t N>
DocumentType::ValueType& swapValueByPointer ( DocumentType &  document,
const CharType(&)  source[N],
typename DocumentType::ValueType &  value 
)

Definition at line 1713 of file pointer.h.

Variable Documentation

const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Initial value:
{
return pointer.GetWithDefault(root, defaultValue, a)
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
Definition: pointer.h:1422
const GenericPointer< typename T::ValueType > T2 defaultValue
Definition: pointer.h:1420
const GenericPointer< typename T::ValueType > & pointer
Definition: pointer.h:1420

Definition at line 1422 of file pointer.h.

const GenericPointer< typename DocumentType::ValueType > T2 defaultValue
Initial value:
{
return pointer.GetWithDefault(document, defaultValue)
const GenericPointer< typename T::ValueType > T2 defaultValue
Definition: pointer.h:1420
const GenericPointer< typename T::ValueType > & pointer
Definition: pointer.h:1420

Definition at line 1420 of file pointer.h.

RAPIDJSON_NAMESPACE_BEGIN const SizeType kPointerInvalidIndex = ~SizeType(0)
static

Represents an invalid index in GenericPointer::Token.

Definition at line 31 of file pointer.h.

const GenericPointer< typename DocumentType::ValueType > & pointer

Definition at line 1420 of file pointer.h.

const CharType(& source

Definition at line 1454 of file pointer.h.

const GenericPointer< typename DocumentType::ValueType > T2 value
Initial value:
{
return pointer.Set(document, value)
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1563
const GenericPointer< typename T::ValueType > & pointer
Definition: pointer.h:1420

Definition at line 1563 of file pointer.h.



xbot_talker
Author(s): wangxiaoyun
autogenerated on Sat Oct 10 2020 03:27:54