Lines Matching refs:Doc
17 Document Doc; in TEST() local
19 DocNode Int1 = Doc.getNode(1), Int2 = Doc.getNode(2); in TEST()
20 DocNode Str1 = Doc.getNode("ab"), Str2 = Doc.getNode("ab"); in TEST()
27 Document Doc; in TEST() local
28 bool Ok = Doc.readFromBlob(StringRef("\xd0\x00", 2), /*Multi=*/false); in TEST()
30 ASSERT_EQ(Doc.getRoot().getKind(), Type::Int); in TEST()
31 ASSERT_EQ(Doc.getRoot().getInt(), 0); in TEST()
35 Document Doc; in TEST() local
36 bool Ok = Doc.readFromBlob(StringRef("\x92\xd0\x01\xc0"), /*Multi=*/false); in TEST()
38 ASSERT_EQ(Doc.getRoot().getKind(), Type::Array); in TEST()
39 auto A = Doc.getRoot().getArray(); in TEST()
47 Ok = Doc.readFromBlob(StringRef("\x91\xd0\x2a"), /*Multi=*/false, in TEST()
61 A = Doc.getRoot().getArray(); in TEST()
71 Document Doc; in TEST() local
72 bool Ok = Doc.readFromBlob(StringRef("\x92\xd0\x01\xc0"), /*Multi=*/false); in TEST()
74 ASSERT_EQ(Doc.getRoot().getKind(), Type::Array); in TEST()
75 auto A = Doc.getRoot().getArray(); in TEST()
83 Ok = Doc.readFromBlob(StringRef("\x91\xd0\x2a"), /*Multi=*/false, in TEST()
91 A = Doc.getRoot().getArray(); in TEST()
104 Document Doc; in TEST() local
105 bool Ok = Doc.readFromBlob(StringRef("\x82\xa3" in TEST()
112 ASSERT_EQ(Doc.getRoot().getKind(), Type::Map); in TEST()
113 auto M = Doc.getRoot().getMap(); in TEST()
122 Ok = Doc.readFromBlob(StringRef("\x82\xa3" in TEST()
146 Ok = Doc.readFromBlob( in TEST()
186 Document Doc; in TEST() local
187 Doc.getRoot() = 1; in TEST()
189 Doc.writeToBlob(Buffer); in TEST()
194 Document Doc; in TEST() local
195 auto A = Doc.getRoot().getArray(/*Convert=*/true); in TEST()
196 A.push_back(Doc.getNode(int64_t(1))); in TEST()
197 A.push_back(Doc.getNode()); in TEST()
199 Doc.writeToBlob(Buffer); in TEST()
204 Document Doc; in TEST() local
205 auto M = Doc.getRoot().getMap(/*Convert=*/true); in TEST()
209 Doc.writeToBlob(Buffer); in TEST()
218 Document Doc; in TEST() local
219 auto A = Doc.getRoot().getArray(/*Convert=*/true); in TEST()
220 A.push_back(Doc.getNode(int64_t(1))); in TEST()
221 A.push_back(Doc.getNode(int64_t(2))); in TEST()
224 Doc.toYAML(OStream); in TEST()
229 Document Doc; in TEST() local
230 bool Ok = Doc.fromYAML("---\n- !int 0x1\n- !str 2\n...\n"); in TEST()
232 ASSERT_EQ(Doc.getRoot().getKind(), Type::Array); in TEST()
233 auto A = Doc.getRoot().getArray(); in TEST()
244 Document Doc; in TEST() local
245 auto M = Doc.getRoot().getMap(/*Convert=*/true); in TEST()
248 auto N = Doc.getMapNode(); in TEST()
253 Doc.toYAML(OStream); in TEST()
263 Document Doc; in TEST() local
264 auto M = Doc.getRoot().getMap(/*Convert=*/true); in TEST()
267 auto N = Doc.getMapNode(); in TEST()
270 M.erase(Doc.getNode("bar")); in TEST()
273 Doc.toYAML(OStream); in TEST()
282 Document Doc; in TEST() local
283 Doc.setHexMode(); in TEST()
284 auto M = Doc.getRoot().getMap(/*Convert=*/true); in TEST()
287 auto N = Doc.getMapNode(); in TEST()
292 Doc.toYAML(OStream); in TEST()
302 Document Doc; in TEST() local
303 bool Ok = Doc.fromYAML("---\nfoo: !int 0x1\nbaz: !str 2\n...\n"); in TEST()
305 ASSERT_EQ(Doc.getRoot().getKind(), Type::Map); in TEST()
306 auto M = Doc.getRoot().getMap(); in TEST()