| 123 | #endif |
| 124 | |
| 125 | bool EndObject(SizeType memberCount = 0) { |
| 126 | (void)memberCount; |
| 127 | RAPIDJSON_ASSERT(Base::level_stack_.GetSize() >= sizeof(typename Base::Level)); |
| 128 | RAPIDJSON_ASSERT(!Base::level_stack_.template Top<typename Base::Level>()->inArray); |
| 129 | bool empty = Base::level_stack_.template Pop<typename Base::Level>(1)->valueCount == 0; |
| 130 | |
| 131 | if (!empty) { |
| 132 | Base::os_->Put('\n'); |
| 133 | WriteIndent(); |
| 134 | } |
| 135 | bool ret = Base::WriteEndObject(); |
| 136 | (void)ret; |
| 137 | RAPIDJSON_ASSERT(ret == true); |
| 138 | if (Base::level_stack_.Empty()) // end of json text |
| 139 | Base::os_->Flush(); |
| 140 | return true; |
| 141 | } |
| 142 | |
| 143 | bool StartArray() { |
| 144 | PrettyPrefix(kArrayType); |