/system/tools/aidl/ |
D | code_writer.cpp | 30 CodeWriter::CodeWriter(std::unique_ptr<std::ostream> ostream) : ostream_(std::move(ostream)) {} in CodeWriter() function in android::aidl::CodeWriter 32 std::string CodeWriter::ApplyIndent(const std::string& str) { in ApplyIndent() 43 bool CodeWriter::Write(const char* format, ...) { in Write() 73 void CodeWriter::Indent() { in Indent() 76 void CodeWriter::Dedent() { in Dedent() 82 bool CodeWriter::Close() { in Close() 91 CodeWriter& CodeWriter::operator<<(const char* s) { in operator <<() 96 CodeWriter& CodeWriter::operator<<(const std::string& str) { in operator <<() 101 CodeWriterPtr CodeWriter::ForFile(const std::string& filename) { in ForFile() 109 return CodeWriterPtr(new CodeWriter(std::move(stream))); in ForFile() [all …]
|
D | code_writer.h | 30 class CodeWriter; variable 31 using CodeWriterPtr = std::unique_ptr<CodeWriter>; 33 class CodeWriter { 48 virtual ~CodeWriter() = default; 49 CodeWriter() = default; 51 CodeWriter& operator<<(const char* s); 52 CodeWriter& operator<<(const std::string& str); 55 CodeWriter(std::unique_ptr<std::ostream> ostream);
|
D | generate_ndk.h | 33 void GenerateSource(CodeWriter& out, const AidlTypenames& types, const AidlInterface& defined_type, 35 void GenerateClassSource(CodeWriter& out, const AidlTypenames& types, 37 void GenerateClientSource(CodeWriter& out, const AidlTypenames& types, 39 void GenerateServerSource(CodeWriter& out, const AidlTypenames& types, 41 void GenerateInterfaceSource(CodeWriter& out, const AidlTypenames& types, 43 void GenerateClientHeader(CodeWriter& out, const AidlTypenames& types, 45 void GenerateServerHeader(CodeWriter& out, const AidlTypenames& types, 47 void GenerateInterfaceHeader(CodeWriter& out, const AidlTypenames& types, 50 void GenerateParcelHeader(CodeWriter& out, const AidlTypenames& types, 52 void GenerateParcelSource(CodeWriter& out, const AidlTypenames& types,
|
D | ast_java.h | 45 class CodeWriter; variable 54 void WriteModifiers(CodeWriter* to, int mod, int mask); 59 virtual void Write(CodeWriter* to) const = 0; 77 void Write(CodeWriter* to) const override; 86 void Write(CodeWriter* to) const override; 99 void WriteDeclaration(CodeWriter* to) const; 100 void Write(CodeWriter* to) const; 111 void Write(CodeWriter* to) const; 125 void Write(CodeWriter* to) const override; 136 void Write(CodeWriter* to) const override; [all …]
|
D | code_writer_unittest.cpp | 22 using android::aidl::CodeWriter; 31 CodeWriterPtr ptr = CodeWriter::ForString(&str); in TEST() 32 CodeWriter& writer = *ptr; in TEST() 40 CodeWriterPtr ptr = CodeWriter::ForString(&str); in TEST() 41 CodeWriter& writer = *ptr; in TEST()
|
D | ast_java.cpp | 36 Write(CodeWriter::ForString(&str).get()); in ToString() 40 void WriteModifiers(CodeWriter* to, int mod, int mask) { in WriteModifiers() 68 void WriteArgumentList(CodeWriter* to, const vector<Expression*>& arguments) { in WriteArgumentList() 80 void Field::Write(CodeWriter* to) const { in Write() 98 void LiteralExpression::Write(CodeWriter* to) const { in Write() 104 void StringLiteralExpression::Write(CodeWriter* to) const { in Write() 112 void Variable::WriteDeclaration(CodeWriter* to) const { in WriteDeclaration() 120 void Variable::Write(CodeWriter* to) const { to->Write("%s", name.c_str()); } in Write() 126 void FieldVariable::Write(CodeWriter* to) const { in Write() 136 void LiteralStatement::Write(CodeWriter* to) const { in Write() [all …]
|
D | aidl_to_cpp_common.cpp | 68 void EnterNamespace(CodeWriter& out, const AidlDefinedType& defined_type) { in EnterNamespace() 74 void LeaveNamespace(CodeWriter& out, const AidlDefinedType& defined_type) { in LeaveNamespace() 95 std::function<void(CodeWriter& w, const string& var_name, bool isNdk)> toJsonValueExpr; 103 [](CodeWriter& c, const string& var_name, bool) { in __anonc907a31c0102() 110 [](CodeWriter& c, const string& var_name, bool) { in __anonc907a31c0202() 117 [](CodeWriter& c, const string& var_name, bool isNdk) { in __anonc907a31c0302() 128 [](CodeWriter& c, const string& var_name, bool) { in __anonc907a31c0402() 135 [](CodeWriter& c, const string& var_name, bool) { in __anonc907a31c0502() 142 [](CodeWriter& c, const string& var_name, bool) { in __anonc907a31c0602() 149 [](CodeWriter& c, const string& var_name, bool) { in __anonc907a31c0702() [all …]
|
D | ast_cpp.h | 27 class CodeWriter; variable 39 virtual void Write(CodeWriter* to) const = 0; 56 void Write(CodeWriter* to) const override; 74 void Write(CodeWriter* to) const override; 95 void Write(CodeWriter* to) const override; 122 void Write(CodeWriter* to) const override; 146 void Write(CodeWriter* to) const override; 161 void Write(CodeWriter* to) const override; 190 void Write(CodeWriter* to) const override; 216 void Write(CodeWriter* to) const override; [all …]
|
D | ast_cpp.cpp | 34 Write(CodeWriter::ForString(&str).get()); in ToString() 40 void LiteralDecl::Write(CodeWriter* to) const { in Write() 56 void ClassDecl::Write(CodeWriter* to) const { in Write() 100 void Enum::Write(CodeWriter* to) const { in Write() 136 void ArgList::Write(CodeWriter* to) const { in Write() 160 void ConstructorDecl::Write(CodeWriter* to) const { in Write() 181 void MacroDecl::Write(CodeWriter* to) const { in Write() 204 void MethodDecl::Write(CodeWriter* to) const { in Write() 247 void StatementBlock::Write(CodeWriter* to) const { in Write() 264 void ConstructorImpl::Write(CodeWriter* to) const { in Write() [all …]
|
D | generate_ndk.cpp | 42 unique_ptr<CodeWriter> i_writer(io_delegate.GetCodeWriter(i_header)); in GenerateNdkInterface() 48 unique_ptr<CodeWriter> bp_writer(io_delegate.GetCodeWriter(bp_header)); in GenerateNdkInterface() 54 unique_ptr<CodeWriter> bn_writer(io_delegate.GetCodeWriter(bn_header)); in GenerateNdkInterface() 58 unique_ptr<CodeWriter> source_writer = io_delegate.GetCodeWriter(output_file); in GenerateNdkInterface() 68 unique_ptr<CodeWriter> header_writer(io_delegate.GetCodeWriter(header_path)); in GenerateNdkParcel() 74 unique_ptr<CodeWriter> bp_writer(io_delegate.GetCodeWriter(bp_header)); in GenerateNdkParcel() 80 unique_ptr<CodeWriter> bn_writer(io_delegate.GetCodeWriter(bn_header)); in GenerateNdkParcel() 84 unique_ptr<CodeWriter> source_writer = io_delegate.GetCodeWriter(output_file); in GenerateNdkParcel() 120 void EnterNdkNamespace(CodeWriter& out, const AidlDefinedType& defined_type) { in EnterNdkNamespace() 124 void LeaveNdkNamespace(CodeWriter& out, const AidlDefinedType& defined_type) { in LeaveNdkNamespace() [all …]
|
D | aidl_to_cpp_common.h | 48 void EnterNamespace(CodeWriter& out, const AidlDefinedType& defined_type); 49 void LeaveNamespace(CodeWriter& out, const AidlDefinedType& defined_type);
|
D | ast_java_unittest.cpp | 54 a_class.Write(CodeWriter::ForString(&actual_output).get()); in TEST() 65 ce.Write(CodeWriter::ForString(&written).get()); in TEST()
|
D | aidl_to_cpp.h | 29 CodeWriter& writer;
|
D | aidl_to_java.h | 58 CodeWriter& writer; // CodeWriter::Write() is mutable
|
D | io_delegate.h | 53 virtual std::unique_ptr<CodeWriter> GetCodeWriter(
|
D | io_delegate.cpp | 179 unique_ptr<CodeWriter> IoDelegate::GetCodeWriter( in GetCodeWriter() 182 return CodeWriter::ForFile(file_path); in GetCodeWriter()
|
D | ast_cpp_unittest.cpp | 98 node.Write(CodeWriter::ForString(&actual_output).get()); in CompareGeneratedCode() 251 decl.Write(CodeWriter::ForString(&written).get()); in TEST_F()
|
D | aidl_to_ndk.h | 42 CodeWriter& writer;
|
/system/tools/sysprop/include/ |
D | CodeWriter.h | 22 class CodeWriter { 24 explicit CodeWriter(std::string indent); 36 CodeWriter(const CodeWriter&) = delete; 37 CodeWriter& operator=(const CodeWriter&) = delete;
|
/system/tools/sysprop/ |
D | CodeWriter.cpp | 30 CodeWriter::CodeWriter(std::string indent) : indent_(std::move(indent)) { in CodeWriter() function in CodeWriter 33 void CodeWriter::Write(const char* format, ...) { in Write() 69 void CodeWriter::Indent() { in Indent() 73 void CodeWriter::Dedent() { in Dedent()
|
D | JavaGen.cpp | 155 void WriteJavaAnnotation(CodeWriter& writer, sysprop::Scope scope); 276 void WriteJavaAnnotation(CodeWriter& writer, sysprop::Scope scope) { in WriteJavaAnnotation() 305 CodeWriter writer(kIndent); in GenerateJavaClass()
|
/system/tools/sysprop/tests/ |
D | CodeWriterUnitTest.cpp | 39 CodeWriter writer(kIndent); in TEST() 61 CodeWriter writer(kIndent); in TEST()
|
/system/tools/xsdc/src/com/android/xsdc/java/ |
D | JavaCodeGenerator.java | 19 import com.android.xsdc.CodeWriter; 88 try (CodeWriter out = new CodeWriter(fs.getPrintWriter(name + ".java"))) { in print() 96 try (CodeWriter out = new CodeWriter(fs.getPrintWriter(name + ".java"))) { in print() 107 try (CodeWriter out = new CodeWriter(fs.getPrintWriter(name + ".java"))) { in print() 113 try (CodeWriter out = new CodeWriter(fs.getPrintWriter("XmlParser.java"))) { in print() 118 private void printEnumClass(CodeWriter out, String name, XsdRestriction restrictionType, in printEnumClass() 143 private void printClass(CodeWriter out, String name, XsdComplexType complexType, in printClass() 235 private void printParser(CodeWriter out, String name, XsdComplexType complexType) in printParser() 314 private void printGetterAndSetter(CodeWriter out, JavaType type, String variableName, in printGetterAndSetter() 342 private void printXmlParser(CodeWriter out) throws JavaCodeGeneratorException { in printXmlParser()
|
/system/tools/aidl/tests/ |
D | fake_io_delegate.cpp | 37 class BrokenCodeWriter : public CodeWriter { 73 std::unique_ptr<CodeWriter> FakeIoDelegate::GetCodeWriter( in GetCodeWriter() 76 return unique_ptr<CodeWriter>(new BrokenCodeWriter); in GetCodeWriter() 80 return CodeWriter::ForString(&written_file_contents_[file_path]); in GetCodeWriter()
|
/system/tools/xsdc/src/com/android/xsdc/ |
D | CodeWriter.java | 22 public class CodeWriter implements Closeable { class 27 public CodeWriter(PrintWriter printWriter) { in CodeWriter() method in CodeWriter
|