1
2
3
4
5
6 #ifndef SNGCPP_AST_SOURCE_CODE_WRITER_INCLUDED
7 #define SNGCPP_AST_SOURCE_CODE_WRITER_INCLUDED
8 #include <sngcpp/ast/AstApi.hpp>
9 #include <string>
10
11 namespace sngcpp { namespace ast {
12
13 class SourceCodeWriter
14 {
15 public:
16 virtual ~SourceCodeWriter();
17 virtual void WriteLineNumber(const std::u32string& lineNumber) = 0;
18 virtual void WriteLineComment(const std::u32string& comment) = 0;
19 virtual void WriteBlockComment(const std::u32string& comment) = 0;
20 virtual void WriteKeyword(const std::u32string& keyword) = 0;
21 virtual void WriteIdentifier(const std::u32string& identifier) = 0;
22 virtual void WriteLink(const std::u32string& identifier, const std::u32string& ref) = 0;
23 virtual void WritePP(const std::u32string& pp) = 0;
24 virtual void WriteChar(const std::u32string& chars) = 0;
25 virtual void WriteString(const std::u32string& string) = 0;
26 virtual void WriteNumber(const std::u32string& number) = 0;
27 virtual void WriteType(const std::u32string& type) = 0;
28 virtual void WriteSpace(int numSpaces) = 0;
29 virtual void WriteSpaces(const std::u32string& spaces) = 0;
30 virtual void WriteOther(const std::u32string& other) = 0;
31 };
32
33 } }
34
35 #endif // SNGCPP_AST_SOURCE_CODE_WRITER_INCLUDED