19 #ifndef RAPIDJSON_POINTER_H_ 20 #define RAPIDJSON_POINTER_H_ 27 RAPIDJSON_DIAG_OFF(
switch -
enum)
28 #elif defined(_MSC_VER) 30 RAPIDJSON_DIAG_OFF(4512)
89 template <
typename ValueType,
typename Allocator = CrtAllocator>
92 typedef typename ValueType::EncodingType
94 typedef typename ValueType::Ch
Ch;
149 #if RAPIDJSON_HAS_STDSTRING 166 Parse(source.c_str(), source.size());
187 Parse(source, length);
319 Ch *p = r.CopyFromRaw(*
this, 1, token.
length + 1);
320 std::memcpy(p, token.
name, (token.
length + 1) *
sizeof(Ch));
346 template <
typename T>
355 #if RAPIDJSON_HAS_STDSTRING 381 if (
sizeof(
Ch) == 1) {
382 Token token = {
reinterpret_cast<Ch *
>(buffer), length, index};
386 for (
size_t i = 0; i <= length; i++) name[i] = static_cast<Ch>(buffer[i]);
400 if (token.IsString())
424 Allocator &GetAllocator() {
return *
allocator_; }
433 size_t GetTokenCount()
const {
return tokenCount_; }
472 if (!IsValid())
return false;
473 if (!rhs.IsValid())
return true;
502 template <
typename OutputStream>
503 bool Stringify(OutputStream &os)
const {
504 return Stringify<false, OutputStream>(os);
512 template <
typename OutputStream>
513 bool StringifyUriFragment(OutputStream &os)
const {
514 return Stringify<true, OutputStream>(os);
539 ValueType &Create(ValueType &root,
540 typename ValueType::AllocatorType &
allocator,
541 bool *alreadyExist = 0)
const {
543 ValueType *v = &root;
546 if (v->IsArray() && t->name[0] ==
'-' && t->length == 1) {
547 v->PushBack(ValueType().Move(), allocator);
548 v = &((*v)[v->Size() - 1]);
551 if (t->index == kPointerInvalidIndex) {
552 if (!v->IsObject()) v->SetObject();
554 if (!v->IsArray() && !v->IsObject())
559 if (t->index >= v->Size()) {
560 v->Reserve(t->index + 1, allocator);
561 while (t->index >= v->Size())
562 v->PushBack(ValueType().Move(), allocator);
565 v = &((*v)[t->index]);
567 typename ValueType::MemberIterator m =
570 if (m == v->MemberEnd()) {
571 v->AddMember(ValueType(t->name, t->length, allocator).Move(),
582 if (alreadyExist) *alreadyExist = exist;
593 template <
typename stackAllocator>
596 stackAllocator> &document,
597 bool *alreadyExist = 0)
const {
598 return Create(document, document.GetAllocator(), alreadyExist);
622 ValueType *Get(ValueType &root,
size_t *unresolvedTokenIndex = 0)
const {
624 ValueType *v = &root;
626 switch (v->GetType()) {
628 typename ValueType::MemberIterator m =
631 if (m == v->MemberEnd())
break;
636 if (t->index == kPointerInvalidIndex || t->index >= v->Size())
break;
637 v = &((*v)[t->index]);
644 if (unresolvedTokenIndex)
645 *unresolvedTokenIndex =
static_cast<size_t>(t -
tokens_);
657 const ValueType *Get(
const ValueType &root,
658 size_t *unresolvedTokenIndex = 0)
const {
659 return Get(const_cast<ValueType &>(root), unresolvedTokenIndex);
678 ValueType &GetWithDefault(
680 typename ValueType::AllocatorType &allocator)
const {
682 ValueType &v = Create(root, allocator, &alreadyExist);
683 return alreadyExist ? v : v.CopyFrom(defaultValue, allocator);
687 ValueType &GetWithDefault(
688 ValueType &root,
const Ch *defaultValue,
689 typename ValueType::AllocatorType &allocator)
const {
691 ValueType &v = Create(root, allocator, &alreadyExist);
692 return alreadyExist ? v : v.SetString(defaultValue, allocator);
695 #if RAPIDJSON_HAS_STDSTRING 696 ValueType &GetWithDefault(
698 ValueType &root,
const std::basic_string<Ch> &defaultValue,
699 typename ValueType::AllocatorType &allocator)
const {
701 ValueType &v = Create(root, allocator, &alreadyExist);
702 return alreadyExist ? v : v.SetString(defaultValue, allocator);
711 template <
typename T>
715 GetWithDefault(ValueType &root, T defaultValue,
716 typename ValueType::AllocatorType &allocator)
const {
717 return GetWithDefault(root, ValueType(defaultValue).Move(), allocator);
721 template <
typename stackAllocator>
722 ValueType &GetWithDefault(
724 stackAllocator> &document,
725 const ValueType &defaultValue)
const {
726 return GetWithDefault(document, defaultValue, document.GetAllocator());
730 template <
typename stackAllocator>
731 ValueType &GetWithDefault(
733 stackAllocator> &document,
734 const Ch *defaultValue)
const {
735 return GetWithDefault(document, defaultValue, document.GetAllocator());
738 #if RAPIDJSON_HAS_STDSTRING 739 template <
typename stackAllocator>
741 ValueType &GetWithDefault(
743 stackAllocator> &document,
744 const std::basic_string<Ch> &defaultValue)
const {
745 return GetWithDefault(document, defaultValue, document.GetAllocator());
754 template <
typename T,
typename stackAllocator>
760 stackAllocator> &document,
761 T defaultValue)
const {
762 return GetWithDefault(document, defaultValue, document.GetAllocator());
781 ValueType &Set(ValueType &root, ValueType &
value,
782 typename ValueType::AllocatorType &allocator)
const {
783 return Create(root, allocator) =
value;
787 ValueType &Set(ValueType &root,
const ValueType &value,
788 typename ValueType::AllocatorType &allocator)
const {
789 return Create(root, allocator).CopyFrom(value, allocator);
793 ValueType &Set(ValueType &root,
const Ch *value,
794 typename ValueType::AllocatorType &allocator)
const {
795 return Create(root, allocator) = ValueType(value, allocator).Move();
798 #if RAPIDJSON_HAS_STDSTRING 799 ValueType &Set(ValueType &root,
const std::basic_string<Ch> &value,
801 typename ValueType::AllocatorType &allocator)
const {
802 return Create(root, allocator) = ValueType(value, allocator).Move();
811 template <
typename T>
815 Set(ValueType &root, T value,
816 typename ValueType::AllocatorType &allocator)
const {
817 return Create(root, allocator) = ValueType(value).Move();
821 template <
typename stackAllocator>
824 stackAllocator> &document,
825 ValueType &value)
const {
826 return Create(document) =
value;
830 template <
typename stackAllocator>
833 stackAllocator> &document,
834 const ValueType &value)
const {
835 return Create(document).CopyFrom(value, document.GetAllocator());
839 template <
typename stackAllocator>
842 stackAllocator> &document,
843 const Ch *value)
const {
844 return Create(document) = ValueType(value, document.GetAllocator()).Move();
847 #if RAPIDJSON_HAS_STDSTRING 848 template <
typename stackAllocator>
852 stackAllocator> &document,
853 const std::basic_string<Ch> &value)
const {
854 return Create(document) = ValueType(value, document.GetAllocator()).Move();
863 template <
typename T,
typename stackAllocator>
868 stackAllocator> &document,
870 return Create(document) =
value;
889 ValueType &
Swap(ValueType &root, ValueType &value,
890 typename ValueType::AllocatorType &allocator)
const {
891 return Create(root, allocator).
Swap(value);
895 template <
typename stackAllocator>
898 stackAllocator> &document,
899 ValueType &value)
const {
900 return Create(document).
Swap(value);
914 bool Erase(ValueType &root)
const {
919 ValueType *v = &root;
922 switch (v->GetType()) {
924 typename ValueType::MemberIterator m =
927 if (m == v->MemberEnd())
return false;
931 if (t->index == kPointerInvalidIndex || t->index >= v->Size())
933 v = &((*v)[t->index]);
940 switch (v->GetType()) {
944 if (last->
index == kPointerInvalidIndex || last->
index >= v->Size())
946 v->Erase(v->Begin() + last->
index);
963 size_t extraNameBufferSize = 0) {
969 nameBufferSize += t->length;
974 (nameBufferSize + extraNameBufferSize) *
sizeof(
Ch)));
979 if (nameBufferSize > 0) {
996 bool NeedPercentEncode(
Ch c)
const {
997 return !((c >=
'0' && c <= '9') || (c >=
'A' && c <=
'Z') ||
998 (c >=
'a' && c <=
'z') || c ==
'-' || c ==
'.' || c ==
'_' ||
1003 #ifndef __clang__ // -Wdocumentation 1023 for (
const Ch *
s = source;
s != source +
length;
s++)
1032 bool uriFragment =
false;
1033 if (source[i] ==
'#') {
1038 if (i != length && source[i] !=
'/') {
1043 while (i < length) {
1048 bool isNumber =
true;
1050 while (i < length && source[i] !=
'/') {
1055 PercentDecodeStream is(&source[i], source + length);
1063 size_t len = os.
PutEnd(begin);
1073 }
else if (NeedPercentEncode(c)) {
1101 if (c < '0' || c >
'9') isNumber =
false;
1106 if (token->
length == 0) isNumber =
false;
1110 if (isNumber && token->
length > 1 && token->
name[0] ==
'0')
1116 for (
size_t j = 0; j < token->
length; j++) {
1150 template <
bool uriFragment,
typename OutputStream>
1151 bool Stringify(OutputStream &os)
const {
1154 if (uriFragment) os.Put(
'#');
1158 for (
size_t j = 0; j < t->length; j++) {
1163 }
else if (c ==
'/') {
1166 }
else if (uriFragment && NeedPercentEncode(c)) {
1173 j += source.
Tell() - 1;
1187 class PercentDecodeStream {
1189 typedef typename ValueType::Ch
Ch;
1196 PercentDecodeStream(
const Ch *source,
const Ch *end)
1197 : src_(source), head_(source), end_(end), valid_(
true) {}
1200 if (*src_ !=
'%' || src_ + 3 > end_) {
1206 for (
int j = 0; j < 2; j++) {
1207 c =
static_cast<Ch
>(c << 4);
1209 if (h >=
'0' && h <=
'9')
1210 c =
static_cast<Ch
>(c + h -
'0');
1211 else if (h >=
'A' && h <=
'F')
1212 c =
static_cast<Ch
>(c + h -
'A' + 10);
1213 else if (h >=
'a' && h <=
'f')
1214 c =
static_cast<Ch
>(c + h -
'a' + 10);
1224 size_t Tell()
const {
return static_cast<size_t>(src_ - head_); }
1225 bool IsValid()
const {
return valid_; }
1236 template <
typename OutputStream>
1241 unsigned char u =
static_cast<unsigned char>(c);
1242 static const char hexDigits[16] = {
'0',
'1',
'2',
'3',
'4',
'5',
1243 '6',
'7',
'8',
'9',
'A',
'B',
1244 'C',
'D',
'E',
'F'};
1246 os_.Put(static_cast<typename OutputStream::Ch>(hexDigits[u >> 4]));
1247 os_.Put(static_cast<typename OutputStream::Ch>(hexDigits[u & 15]));
1272 template <
typename T>
1275 typename T::AllocatorType &
a) {
1276 return pointer.Create(root, a);
1279 template <
typename T,
typename CharType,
size_t N>
1281 const CharType (&
source)[N],
1282 typename T::AllocatorType &
a) {
1288 template <
typename DocumentType>
1290 DocumentType &document,
1292 return pointer.Create(document);
1295 template <
typename DocumentType,
typename CharType,
size_t N>
1297 DocumentType &document,
const CharType (&
source)[N]) {
1304 template <
typename T>
1307 size_t *unresolvedTokenIndex = 0) {
1308 return pointer.Get(root, unresolvedTokenIndex);
1311 template <
typename T>
1314 size_t *unresolvedTokenIndex = 0) {
1315 return pointer.Get(root, unresolvedTokenIndex);
1318 template <
typename T,
typename CharType,
size_t N>
1320 size_t *unresolvedTokenIndex = 0) {
1322 .Get(root, unresolvedTokenIndex);
1325 template <
typename T,
typename CharType,
size_t N>
1327 const T &root,
const CharType (&
source)[N],
1328 size_t *unresolvedTokenIndex = 0) {
1330 .Get(root, unresolvedTokenIndex);
1335 template <
typename T>
1338 const typename T::ValueType &
defaultValue,
typename T::AllocatorType &
a) {
1339 return pointer.GetWithDefault(root, defaultValue, a);
1342 template <
typename T>
1345 const typename T::Ch *
defaultValue,
typename T::AllocatorType &
a) {
1346 return pointer.GetWithDefault(root, defaultValue, a);
1349 #if RAPIDJSON_HAS_STDSTRING 1350 template <
typename T>
1354 typename T::AllocatorType &
a) {
1355 return pointer.GetWithDefault(root, defaultValue, a);
1359 template <
typename T,
typename T2>
1362 (
typename T::ValueType &))
1365 T2 defaultValue,
typename T::AllocatorType &a) {
1366 return pointer.GetWithDefault(root, defaultValue, a);
1369 template <
typename T,
typename CharType,
size_t N>
1371 T &root,
const CharType (&
source)[N],
1372 const typename T::ValueType &
defaultValue,
typename T::AllocatorType &
a) {
1374 .GetWithDefault(root, defaultValue, a);
1377 template <
typename T,
typename CharType,
size_t N>
1380 typename T::AllocatorType &
a) {
1382 .GetWithDefault(root, defaultValue, a);
1385 #if RAPIDJSON_HAS_STDSTRING 1386 template <
typename T,
typename CharType,
size_t N>
1388 T &root,
const CharType (&
source)[N],
1390 typename T::AllocatorType &
a) {
1392 .GetWithDefault(root, defaultValue, a);
1396 template <
typename T,
typename CharType,
size_t N,
typename T2>
1399 (
typename T::ValueType &))
1401 T2 defaultValue, typename T::AllocatorType &a) {
1403 .GetWithDefault(root, defaultValue, a);
1408 template <
typename DocumentType>
1410 DocumentType &document,
1412 const typename DocumentType::ValueType &
defaultValue) {
1413 return pointer.GetWithDefault(document, defaultValue);
1416 template <
typename DocumentType>
1418 DocumentType &document,
1421 return pointer.GetWithDefault(document, defaultValue);
1424 #if RAPIDJSON_HAS_STDSTRING 1425 template <
typename DocumentType>
1427 DocumentType &document,
1429 const std::basic_string<typename DocumentType::Ch> &
defaultValue) {
1430 return pointer.GetWithDefault(document, defaultValue);
1434 template <
typename DocumentType,
typename T2>
1437 (
typename DocumentType::ValueType &))
1439 DocumentType &document,
1442 return pointer.GetWithDefault(document, defaultValue);
1445 template <
typename DocumentType,
typename CharType,
size_t N>
1447 DocumentType &document,
const CharType (&
source)[N],
1448 const typename DocumentType::ValueType &defaultValue) {
1450 .GetWithDefault(document, defaultValue);
1453 template <
typename DocumentType,
typename CharType,
size_t N>
1455 DocumentType &document,
const CharType (&
source)[N],
1456 const typename DocumentType::Ch *defaultValue) {
1458 .GetWithDefault(document, defaultValue);
1461 #if RAPIDJSON_HAS_STDSTRING 1462 template <
typename DocumentType,
typename CharType,
size_t N>
1464 DocumentType &document,
const CharType (&
source)[N],
1465 const std::basic_string<typename DocumentType::Ch> &defaultValue) {
1467 .GetWithDefault(document, defaultValue);
1471 template <
typename DocumentType,
typename CharType,
size_t N,
typename T2>
1474 (
typename DocumentType::ValueType &))
1476 const CharType (&
source)[N], T2 defaultValue) {
1478 .GetWithDefault(document, defaultValue);
1483 template <
typename T>
1486 typename T::ValueType &
value,
typename T::AllocatorType &
a) {
1487 return pointer.Set(root, value, a);
1490 template <
typename T>
1493 const typename T::ValueType &
value,
typename T::AllocatorType &
a) {
1494 return pointer.Set(root, value, a);
1497 template <
typename T>
1500 const typename T::Ch *
value,
typename T::AllocatorType &
a) {
1501 return pointer.Set(root, value, a);
1504 #if RAPIDJSON_HAS_STDSTRING 1505 template <
typename T>
1508 const std::basic_string<typename T::Ch> &
value,
1509 typename T::AllocatorType &
a) {
1510 return pointer.Set(root, value, a);
1514 template <
typename T,
typename T2>
1517 (
typename T::ValueType &))
1519 T2 value, typename T::AllocatorType &a) {
1520 return pointer.Set(root, value, a);
1523 template <
typename T,
typename CharType,
size_t N>
1525 typename T::ValueType &
value,
1526 typename T::AllocatorType &
a) {
1528 .Set(root, value, a);
1531 template <
typename T,
typename CharType,
size_t N>
1533 const typename T::ValueType &
value,
1534 typename T::AllocatorType &
a) {
1536 .Set(root, value, a);
1539 template <
typename T,
typename CharType,
size_t N>
1541 const typename T::Ch *
value,
1542 typename T::AllocatorType &
a) {
1544 .Set(root, value, a);
1547 #if RAPIDJSON_HAS_STDSTRING 1548 template <
typename T,
typename CharType,
size_t N>
1550 T &root,
const CharType (&
source)[N],
1551 const std::basic_string<typename T::Ch> &
value,
1552 typename T::AllocatorType &
a) {
1554 .Set(root, value, a);
1558 template <
typename T,
typename CharType,
size_t N,
typename T2>
1561 (
typename T::ValueType &))
1563 typename T::AllocatorType &a) {
1565 .Set(root, value, a);
1570 template <
typename DocumentType>
1572 DocumentType &document,
1574 typename DocumentType::ValueType &value) {
1575 return pointer.Set(document, value);
1578 template <
typename DocumentType>
1580 DocumentType &document,
1582 const typename DocumentType::ValueType &value) {
1583 return pointer.Set(document, value);
1586 template <
typename DocumentType>
1588 DocumentType &document,
1590 const typename DocumentType::Ch *value) {
1591 return pointer.Set(document, value);
1594 #if RAPIDJSON_HAS_STDSTRING 1595 template <
typename DocumentType>
1597 DocumentType &document,
1599 const std::basic_string<typename DocumentType::Ch> &value) {
1600 return pointer.Set(document, value);
1604 template <
typename DocumentType,
typename T2>
1607 (
typename DocumentType::ValueType &))
1609 DocumentType &document,
1611 return pointer.Set(document, value);
1614 template <
typename DocumentType,
typename CharType,
size_t N>
1616 DocumentType &document,
const CharType (&
source)[N],
1617 typename DocumentType::ValueType &value) {
1619 .Set(document, value);
1622 template <
typename DocumentType,
typename CharType,
size_t N>
1624 DocumentType &document,
const CharType (&
source)[N],
1625 const typename DocumentType::ValueType &value) {
1627 .Set(document, value);
1630 template <
typename DocumentType,
typename CharType,
size_t N>
1632 DocumentType &document,
const CharType (&
source)[N],
1633 const typename DocumentType::Ch *value) {
1635 .Set(document, value);
1638 #if RAPIDJSON_HAS_STDSTRING 1639 template <
typename DocumentType,
typename CharType,
size_t N>
1641 DocumentType &document,
const CharType (&
source)[N],
1642 const std::basic_string<typename DocumentType::Ch> &value) {
1644 .Set(document, value);
1648 template <
typename DocumentType,
typename CharType,
size_t N,
typename T2>
1651 (
typename DocumentType::ValueType &))
1655 .Set(document, value);
1660 template <
typename T>
1663 typename T::ValueType &value,
typename T::AllocatorType &a) {
1664 return pointer.
Swap(root, value, a);
1667 template <
typename T,
typename CharType,
size_t N>
1669 typename T::ValueType &value,
1670 typename T::AllocatorType &a) {
1672 .
Swap(root, value, a);
1675 template <
typename DocumentType>
1677 DocumentType &document,
1679 typename DocumentType::ValueType &value) {
1680 return pointer.
Swap(document, value);
1683 template <
typename DocumentType,
typename CharType,
size_t N>
1685 DocumentType &document,
const CharType (&
source)[N],
1686 typename DocumentType::ValueType &value) {
1688 .
Swap(document, value);
1693 template <
typename T>
1696 return pointer.Erase(root);
1699 template <
typename T,
typename CharType,
size_t N>
1708 #if defined(__clang__) || defined(_MSC_VER) 1712 #endif // RAPIDJSON_POINTER_H_ GenericPointer(const Token *tokens, size_t tokenCount)
Constructor with user-supplied tokens.
T::ValueType & GetValueByPointerWithDefault(T &root, const GenericPointer< typename T::ValueType > &pointer, const typename T::ValueType &defaultValue, typename T::AllocatorType &a)
char * u64toa(uint64_t value, char *buffer)
const CharType(& source)[N]
RAPIDJSON_NAMESPACE_BEGIN typedef unsigned SizeType
Size type (for string lengths, array sizes, etc.)
#define RAPIDJSON_ASSERT(x)
Assertion.
Ch * nameBuffer_
A buffer containing all names in tokens.
#define RAPIDJSON_NAMESPACE_END
provide custom rapidjson namespace (closing expression)
TFSIMD_FORCE_INLINE bool operator==(const Matrix3x3 &m1, const Matrix3x3 &m2)
ValueType::EncodingType EncodingType
Encoding type from Value.
GenericPointer(const Ch *source, size_t length, Allocator *allocator=0)
PointerParseErrorCode parseErrorCode_
Parsing error code.
Represents a JSON value. Use Value for UTF8 encoding and default allocator.
GenericPointer(const GenericPointer &rhs)
Copy constructor.
Token * tokens_
A list of tokens.
static RAPIDJSON_NAMESPACE_BEGIN const SizeType kPointerInvalidIndex
Represents an invalid index in GenericPointer::Token.
GenericPointer Append(const Ch *name, SizeType length, Allocator *allocator=0) const
Append a name token with length, and return a new Pointer.
T::ValueType & SwapValueByPointer(T &root, const GenericPointer< typename T::ValueType > &pointer, typename T::ValueType &value, typename T::AllocatorType &a)
#define RAPIDJSON_NAMESPACE_BEGIN
provide custom rapidjson namespace (opening expression)
A token is the basic units of internal representation.
A document for parsing JSON text as DOM.
A read-write string stream.
SizeType length
Length of the name.
GenericPointer(const Ch *source, Allocator *allocator=0)
Constructor that parses a string or URI fragment representation.
size_t parseErrorOffset_
Offset in code unit when parsing fail.
#define RAPIDJSON_NEW(TypeName)
! customization point for global new
friend void swap(GenericPointer &a, GenericPointer &b) RAPIDJSON_NOEXCEPT
free-standing swap function helper
GenericPointer & operator=(const GenericPointer &rhs)
Assignment operator.
GenericPointer< Value > Pointer
GenericPointer for Value (UTF-8, default allocator).
PercentEncodeStream(OutputStream &os)
size_t tokenCount_
Number of tokens in tokens_.
TFSIMD_FORCE_INLINE bool operator!=(const Vector3 &other) const
RAPIDJSON_DISABLEIF_RETURN((internal::NotExpr< internal::IsSame< typename internal::RemoveConst< T >::Type, Ch >>),(GenericPointer)) Append(T *name
Append a name token without length, and return a new Pointer.
void Swap(T &a, T &b) RAPIDJSON_NOEXCEPT
Custom swap() to avoid dependency on C++ <algorithm> header.
#define RAPIDJSON_DELETE(x)
! customization point for global delete
char * u32toa(uint32_t value, char *buffer)
T::ValueType & CreateValueByPointer(T &root, const GenericPointer< typename T::ValueType > &pointer, typename T::AllocatorType &a)
GenericPointer(const GenericPointer &rhs, Allocator *allocator)
Copy constructor.
const GenericPointer< typename T::ValueType > T2 T::AllocatorType & a
ValueType::Ch Ch
Character type from Value.
PointerParseErrorCode
Error code of parsing.
const GenericPointer< typename T::ValueType > T2 value
GenericPointer Append(const Token &token, Allocator *allocator=0) const
Append a token and return a new Pointer.
GenericPointer & Swap(GenericPointer &other) RAPIDJSON_NOEXCEPT
Swap the content of this pointer with an other.
bool EraseValueByPointer(T &root, const GenericPointer< typename T::ValueType > &pointer)
const GenericPointer< typename T::ValueType > T2 defaultValue
SizeType StrLen(const Ch *s)
Custom strlen() which works on different character types.
Reference to a constant string (not taking a copy)
const GenericPointer< typename T::ValueType > & pointer
Allocator * ownAllocator_
Allocator owned by this Pointer.
T::ValueType & SetValueByPointer(T &root, const GenericPointer< typename T::ValueType > &pointer, typename T::ValueType &value, typename T::AllocatorType &a)
GenericPointer(Allocator *allocator=0)
Default constructor.
T::ValueType * GetValueByPointer(T &root, const GenericPointer< typename T::ValueType > &pointer, size_t *unresolvedTokenIndex=0)
~GenericPointer()
Destructor.