🛰️航天仿真算法库 SpaceAST 0.0.1
载入中...
搜索中...
未找到
BKVSaxPrint.hpp
浏览该文件的文档.
1
20
21#pragma once
22
23#include "AstGlobal.h"
24#include "BKVSax.hpp"
25#include "AstUtil/ScopedPtr.hpp"
26#include <cstdio>
27
28AST_NAMESPACE_BEGIN
29
33class AST_UTIL_API BKVSaxPrint : public BKVSax
34{
35public:
37
38 BKVSaxPrint(const BKVSaxPrint&) = delete;
39 BKVSaxPrint& operator=(const BKVSaxPrint&) = delete;
40
41 explicit BKVSaxPrint(StringView filepath);
43 errc_t begin(StringView name) override;
44 errc_t end(StringView name) override;
45 using BKVSax::keyValue;
46 errc_t keyValue(StringView key, const ValueView& value) override;
47protected:
48 FILE* file_;
49 int indent_;
50 int depth_;
51};
52
53AST_NAMESPACE_END
键值对打印器(BlockKeyValueSaxPrint)
定义 BKVSaxPrint.hpp:34
键值对解析器SAX接口(BlockKeyValueSax)
定义 BKVSax.hpp:36
virtual errc_t keyValue(StringView key, const ValueView &value)=0
迭代解析一个键值对
值视图类
定义 ValueView.hpp:41