summaryrefslogtreecommitdiff
path: root/graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp')
-rw-r--r--graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp b/graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp
index c34a050dc8..3ef72314ef 100644
--- a/graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp
+++ b/graphics/asymptote/LspCpp/third_party/rapidjson/example/filterkey/filterkey.cpp
@@ -19,7 +19,7 @@ class FilterKeyHandler {
public:
typedef char Ch;
- FilterKeyHandler(OutputHandler& outputHandler, const Ch* keyString, SizeType keyLength) :
+ FilterKeyHandler(OutputHandler& outputHandler, const Ch* keyString, SizeType keyLength) :
outputHandler_(outputHandler), keyString_(keyString), keyLength_(keyLength), filterValueDepth_(), filteredKeyCount_()
{}
@@ -32,8 +32,8 @@ public:
bool Double(double d) { return filterValueDepth_ > 0 ? EndValue() : outputHandler_.Double(d) && EndValue(); }
bool RawNumber(const Ch* str, SizeType len, bool copy) { return filterValueDepth_ > 0 ? EndValue() : outputHandler_.RawNumber(str, len, copy) && EndValue(); }
bool String (const Ch* str, SizeType len, bool copy) { return filterValueDepth_ > 0 ? EndValue() : outputHandler_.String (str, len, copy) && EndValue(); }
-
- bool StartObject() {
+
+ bool StartObject() {
if (filterValueDepth_ > 0) {
filterValueDepth_++;
return true;
@@ -43,9 +43,9 @@ public:
return outputHandler_.StartObject();
}
}
-
- bool Key(const Ch* str, SizeType len, bool copy) {
- if (filterValueDepth_ > 0)
+
+ bool Key(const Ch* str, SizeType len, bool copy) {
+ if (filterValueDepth_ > 0)
return true;
else if (len == keyLength_ && std::memcmp(str, keyString_, len) == 0) {
filterValueDepth_ = 1;
@@ -97,7 +97,7 @@ private:
filterValueDepth_ = 0;
return true;
}
-
+
OutputHandler& outputHandler_;
const char* keyString_;
const SizeType keyLength_;