| 520 | } |
| 521 | |
| 522 | inline |
| 523 | void JsonSax::FillCurrentTarget(Value value) |
| 524 | { |
| 525 | if (m_Stack.empty()) { |
| 526 | m_Root = value; |
| 527 | } else { |
| 528 | auto& node (m_Stack.back()); |
| 529 | |
| 530 | if (node.m_Dictionary) { |
| 531 | node.m_Dictionary->Set(node.m_CurrentKey, value); |
| 532 | } else { |
| 533 | node.m_Array->Add(value); |
| 534 | } |
| 535 | } |
| 536 | } |
| 537 | |
| 538 | void JsonSax::CheckDepthLimit() const |
| 539 | { |