OLD | NEW |
1 // Protocol Buffers - Google's data interchange format | 1 // Protocol Buffers - Google's data interchange format |
2 // Copyright 2008 Google Inc. All rights reserved. | 2 // Copyright 2008 Google Inc. All rights reserved. |
3 // https://developers.google.com/protocol-buffers/ | 3 // https://developers.google.com/protocol-buffers/ |
4 // | 4 // |
5 // Redistribution and use in source and binary forms, with or without | 5 // Redistribution and use in source and binary forms, with or without |
6 // modification, are permitted provided that the following conditions are | 6 // modification, are permitted provided that the following conditions are |
7 // met: | 7 // met: |
8 // | 8 // |
9 // * Redistributions of source code must retain the above copyright | 9 // * Redistributions of source code must retain the above copyright |
10 // notice, this list of conditions and the following disclaimer. | 10 // notice, this list of conditions and the following disclaimer. |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 struct Options; | 43 struct Options; |
44 | 44 |
45 class SourceGeneratorBase { | 45 class SourceGeneratorBase { |
46 protected: | 46 protected: |
47 SourceGeneratorBase(const FileDescriptor* descriptor, const Options* options); | 47 SourceGeneratorBase(const FileDescriptor* descriptor, const Options* options); |
48 virtual ~SourceGeneratorBase(); | 48 virtual ~SourceGeneratorBase(); |
49 | 49 |
50 std::string class_access_level(); | 50 std::string class_access_level(); |
51 const Options* options(); | 51 const Options* options(); |
52 | 52 |
| 53 // Write any attributes used to decorate generated function members (methods a
nd properties). |
| 54 // Should not be used to decorate types. |
53 void WriteGeneratedCodeAttributes(io::Printer* printer); | 55 void WriteGeneratedCodeAttributes(io::Printer* printer); |
54 | 56 |
55 private: | 57 private: |
56 const FileDescriptor* descriptor_; | 58 const FileDescriptor* descriptor_; |
57 const Options *options_; | 59 const Options *options_; |
58 | 60 |
59 GOOGLE_DISALLOW_EVIL_CONSTRUCTORS(SourceGeneratorBase); | 61 GOOGLE_DISALLOW_EVIL_CONSTRUCTORS(SourceGeneratorBase); |
60 }; | 62 }; |
61 | 63 |
62 } // namespace csharp | 64 } // namespace csharp |
63 } // namespace compiler | 65 } // namespace compiler |
64 } // namespace protobuf | 66 } // namespace protobuf |
65 } // namespace google | 67 } // namespace google |
66 | 68 |
67 #endif // GOOGLE_PROTOBUF_COMPILER_CSHARP_SOURCE_GENERATOR_BASE_H__ | 69 #endif // GOOGLE_PROTOBUF_COMPILER_CSHARP_SOURCE_GENERATOR_BASE_H__ |
68 | 70 |
OLD | NEW |