objectivec_helpers.h
Go to the documentation of this file.
1 // Protocol Buffers - Google's data interchange format
2 // Copyright 2008 Google Inc. All rights reserved.
3 // https://developers.google.com/protocol-buffers/
4 //
5 // Redistribution and use in source and binary forms, with or without
6 // modification, are permitted provided that the following conditions are
7 // met:
8 //
9 // * Redistributions of source code must retain the above copyright
10 // notice, this list of conditions and the following disclaimer.
11 // * Redistributions in binary form must reproduce the above
12 // copyright notice, this list of conditions and the following disclaimer
13 // in the documentation and/or other materials provided with the
14 // distribution.
15 // * Neither the name of Google Inc. nor the names of its
16 // contributors may be used to endorse or promote products derived from
17 // this software without specific prior written permission.
18 //
19 // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20 // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21 // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
22 // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
23 // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
24 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
25 // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26 // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27 // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28 // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29 // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 
31 // Helper functions for generating ObjectiveC code.
32 
33 #ifndef GOOGLE_PROTOBUF_COMPILER_OBJECTIVEC_HELPERS_H__
34 #define GOOGLE_PROTOBUF_COMPILER_OBJECTIVEC_HELPERS_H__
35 
36 #include <string>
37 #include <vector>
38 
41 
42 #include <google/protobuf/port_def.inc>
43 
44 namespace google {
45 namespace protobuf {
46 namespace compiler {
47 namespace objectivec {
48 
49 // Generator options (see objectivec_generator.cc for a description of each):
50 struct Options {
51  Options();
53  std::vector<string> expected_prefixes_suppressions;
56 };
57 
58 // Escape C++ trigraphs by escaping question marks to "\?".
59 string PROTOC_EXPORT EscapeTrigraphs(const string& to_escape);
60 
61 // Strips ".proto" or ".protodevel" from the end of a filename.
62 string PROTOC_EXPORT StripProto(const string& filename);
63 
64 // Remove white space from either end of a StringPiece.
65 void PROTOC_EXPORT TrimWhitespace(StringPiece* input);
66 
67 // Returns true if the name requires a ns_returns_not_retained attribute applied
68 // to it.
69 bool PROTOC_EXPORT IsRetainedName(const string& name);
70 
71 // Returns true if the name starts with "init" and will need to have special
72 // handling under ARC.
73 bool PROTOC_EXPORT IsInitName(const string& name);
74 
75 // Gets the objc_class_prefix.
76 string PROTOC_EXPORT FileClassPrefix(const FileDescriptor* file);
77 
78 // Gets the path of the file we're going to generate (sans the .pb.h
79 // extension). The path will be dependent on the objectivec package
80 // declared in the proto package.
81 string PROTOC_EXPORT FilePath(const FileDescriptor* file);
82 
83 // Just like FilePath(), but without the directory part.
84 string PROTOC_EXPORT FilePathBasename(const FileDescriptor* file);
85 
86 // Gets the name of the root class we'll generate in the file. This class
87 // is not meant for external consumption, but instead contains helpers that
88 // the rest of the classes need
89 string PROTOC_EXPORT FileClassName(const FileDescriptor* file);
90 
91 // These return the fully-qualified class name corresponding to the given
92 // descriptor.
93 string PROTOC_EXPORT ClassName(const Descriptor* descriptor);
94 string PROTOC_EXPORT ClassName(const Descriptor* descriptor,
95  string* out_suffix_added);
96 string PROTOC_EXPORT EnumName(const EnumDescriptor* descriptor);
97 
98 // Returns the fully-qualified name of the enum value corresponding to the
99 // the descriptor.
100 string PROTOC_EXPORT EnumValueName(const EnumValueDescriptor* descriptor);
101 
102 // Returns the name of the enum value corresponding to the descriptor.
103 string PROTOC_EXPORT EnumValueShortName(const EnumValueDescriptor* descriptor);
104 
105 // Reverse what an enum does.
106 string PROTOC_EXPORT UnCamelCaseEnumShortName(const string& name);
107 
108 // Returns the name to use for the extension (used as the method off the file's
109 // Root class).
110 string PROTOC_EXPORT ExtensionMethodName(const FieldDescriptor* descriptor);
111 
112 // Returns the transformed field name.
113 string PROTOC_EXPORT FieldName(const FieldDescriptor* field);
114 string PROTOC_EXPORT FieldNameCapitalized(const FieldDescriptor* field);
115 
116 // Returns the transformed oneof name.
117 string PROTOC_EXPORT OneofEnumName(const OneofDescriptor* descriptor);
118 string PROTOC_EXPORT OneofName(const OneofDescriptor* descriptor);
119 string PROTOC_EXPORT OneofNameCapitalized(const OneofDescriptor* descriptor);
120 
121 inline bool HasFieldPresence(const FileDescriptor* file) {
122  return file->syntax() != FileDescriptor::SYNTAX_PROTO3;
123 }
124 
126  return file->syntax() == FileDescriptor::SYNTAX_PROTO3;
127 }
128 
130  return descriptor->options().map_entry();
131 }
132 
133 // Reverse of the above.
134 string PROTOC_EXPORT UnCamelCaseFieldName(const string& name,
135  const FieldDescriptor* field);
136 
149 };
150 
151 enum FlagType {
155 };
156 
157 template<class TDescriptor>
159  const TDescriptor* descriptor,
160  const FileDescriptor* file = NULL,
161  bool preSpace = true, bool postNewline = false) {
162  bool isDeprecated = descriptor->options().deprecated();
163  // The file is only passed when checking Messages & Enums, so those types
164  // get tagged. At the moment, it doesn't seem to make sense to tag every
165  // field or enum value with when the file is deprecated.
166  bool isFileLevelDeprecation = false;
167  if (!isDeprecated && file) {
168  isFileLevelDeprecation = file->options().deprecated();
169  isDeprecated = isFileLevelDeprecation;
170  }
171  if (isDeprecated) {
172  string message;
173  const FileDescriptor* sourceFile = descriptor->file();
174  if (isFileLevelDeprecation) {
175  message = sourceFile->name() + " is deprecated.";
176  } else {
177  message = descriptor->full_name() + " is deprecated (see " +
178  sourceFile->name() + ").";
179  }
180 
181  string result = string("GPB_DEPRECATED_MSG(\"") + message + "\")";
182  if (preSpace) {
183  result.insert(0, " ");
184  }
185  if (postNewline) {
186  result.append("\n");
187  }
188  return result;
189  } else {
190  return "";
191  }
192 }
193 
194 string PROTOC_EXPORT GetCapitalizedType(const FieldDescriptor* field);
195 
196 ObjectiveCType PROTOC_EXPORT
198 
200  return GetObjectiveCType(field->type());
201 }
202 
203 bool PROTOC_EXPORT IsPrimitiveType(const FieldDescriptor* field);
204 bool PROTOC_EXPORT IsReferenceType(const FieldDescriptor* field);
205 
206 string PROTOC_EXPORT GPBGenericValueFieldName(const FieldDescriptor* field);
207 string PROTOC_EXPORT DefaultValue(const FieldDescriptor* field);
208 bool PROTOC_EXPORT HasNonZeroDefaultValue(const FieldDescriptor* field);
209 
210 string PROTOC_EXPORT BuildFlagsString(const FlagType type,
211  const std::vector<string>& strings);
212 
213 // Builds HeaderDoc/appledoc style comments out of the comments in the .proto
214 // file.
215 string PROTOC_EXPORT BuildCommentsString(const SourceLocation& location,
216  bool prefer_single_line);
217 
218 // The name the commonly used by the library when built as a framework.
219 // This lines up to the name used in the CocoaPod.
220 extern PROTOC_EXPORT const char* const ProtobufLibraryFrameworkName;
221 // Returns the CPP symbol name to use as the gate for framework style imports
222 // for the given framework name to use.
223 string PROTOC_EXPORT
224 ProtobufFrameworkImportSymbol(const string& framework_name);
225 
226 // Checks if the file is one of the proto's bundled with the library.
227 bool PROTOC_EXPORT
229 
230 // Checks the prefix for the given files and outputs any warnings as needed. If
231 // there are flat out errors, then out_error is filled in with the first error
232 // and the result is false.
233 bool PROTOC_EXPORT
234 ValidateObjCClassPrefixes(const std::vector<const FileDescriptor*>& files,
235  const Options& generation_options, string* out_error);
236 
237 // Generate decode data needed for ObjC's GPBDecodeTextFormatName() to transform
238 // the input into the expected output.
239 class PROTOC_EXPORT TextFormatDecodeData {
240  public:
243 
245  TextFormatDecodeData& operator=(const TextFormatDecodeData&) = delete;
246 
247  void AddString(int32 key, const string& input_for_decode,
248  const string& desired_output);
249  size_t num_entries() const { return entries_.size(); }
250  string Data() const;
251 
252  static string DecodeDataForString(const string& input_for_decode,
253  const string& desired_output);
254 
255  private:
256  typedef std::pair<int32, string> DataEntry;
257  std::vector<DataEntry> entries_;
258 };
259 
260 // Helper for parsing simple files.
261 class PROTOC_EXPORT LineConsumer {
262  public:
263  LineConsumer();
264  virtual ~LineConsumer();
265  virtual bool ConsumeLine(const StringPiece& line, string* out_error) = 0;
266 };
267 
268 bool PROTOC_EXPORT ParseSimpleFile(const string& path,
269  LineConsumer* line_consumer,
270  string* out_error);
271 
272 // Helper class for parsing framework import mappings and generating
273 // import statements.
274 class PROTOC_EXPORT ImportWriter {
275  public:
276  ImportWriter(const string& generate_for_named_framework,
277  const string& named_framework_to_proto_path_mappings_path,
278  bool include_wkt_imports);
279  ~ImportWriter();
280 
281  void AddFile(const FileDescriptor* file, const string& header_extension);
282  void Print(io::Printer *printer) const;
283 
284  private:
286  public:
287  ProtoFrameworkCollector(std::map<string, string>* inout_proto_file_to_framework_name)
288  : map_(inout_proto_file_to_framework_name) {}
289 
290  virtual bool ConsumeLine(const StringPiece& line, string* out_error);
291 
292  private:
293  std::map<string, string>* map_;
294  };
295 
296  void ParseFrameworkMappings();
297 
301  std::map<string, string> proto_file_to_framework_name_;
303 
304  std::vector<string> protobuf_framework_imports_;
305  std::vector<string> protobuf_non_framework_imports_;
306  std::vector<string> other_framework_imports_;
307  std::vector<string> other_imports_;
308 };
309 
310 } // namespace objectivec
311 } // namespace compiler
312 } // namespace protobuf
313 } // namespace google
314 
315 #include <google/protobuf/port_undef.inc>
316 
317 #endif // GOOGLE_PROTOBUF_COMPILER_OBJECTIVEC_HELPERS_H__
google::protobuf::compiler::objectivec::ProtobufLibraryFrameworkName
const char *const ProtobufLibraryFrameworkName
Definition: objectivec_helpers.cc:984
google::protobuf::compiler::objectivec::IsReferenceType
bool IsReferenceType(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:732
google::protobuf::FieldDescriptor::Type
Type
Definition: src/google/protobuf/descriptor.h:521
google::protobuf::compiler::objectivec::ParseSimpleFile
bool ParseSimpleFile(const string &path, LineConsumer *line_consumer, string *out_error)
Definition: objectivec_helpers.cc:1525
google::protobuf::compiler::objectivec::TextFormatDecodeData
Definition: objectivec_helpers.h:239
google::protobuf::compiler::objectivec::Options::named_framework_to_proto_path_mappings_path
string named_framework_to_proto_path_mappings_path
Definition: objectivec_helpers.h:55
google::protobuf::compiler::objectivec::HasFieldPresence
bool HasFieldPresence(const FileDescriptor *file)
Definition: objectivec_helpers.h:121
google::protobuf::compiler::objectivec::ImportWriter::other_framework_imports_
std::vector< string > other_framework_imports_
Definition: objectivec_helpers.h:306
name
GLuint const GLchar * name
Definition: glcorearb.h:3055
google::protobuf::FieldDescriptor
Definition: src/google/protobuf/descriptor.h:515
google::protobuf::compiler::objectivec::ImportWriter::generate_for_named_framework_
const string generate_for_named_framework_
Definition: objectivec_helpers.h:298
google::protobuf::compiler::objectivec::ImportWriter::ProtoFrameworkCollector::map_
std::map< string, string > * map_
Definition: objectivec_helpers.h:293
google::protobuf::compiler::objectivec::OneofNameCapitalized
string OneofNameCapitalized(const OneofDescriptor *descriptor)
Definition: objectivec_helpers.cc:578
google::protobuf::compiler::objectivec::Options::generate_for_named_framework
string generate_for_named_framework
Definition: objectivec_helpers.h:54
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_INT32
@ OBJECTIVECTYPE_INT32
Definition: objectivec_helpers.h:138
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_UINT32
@ OBJECTIVECTYPE_UINT32
Definition: objectivec_helpers.h:139
NULL
NULL
Definition: test_security_zap.cpp:405
field_type
zend_class_entry * field_type
Definition: php/ext/google/protobuf/message.c:2028
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_STRING
@ OBJECTIVECTYPE_STRING
Definition: objectivec_helpers.h:145
google::protobuf::compiler::objectivec::ImportWriter
Definition: objectivec_helpers.h:274
input
std::string input
Definition: tokenizer_unittest.cc:197
google::protobuf::compiler::objectivec::HasPreservingUnknownEnumSemantics
bool HasPreservingUnknownEnumSemantics(const FileDescriptor *file)
Definition: objectivec_helpers.h:125
google::protobuf::compiler::objectivec::EnumValueShortName
string EnumValueShortName(const EnumValueDescriptor *descriptor)
Definition: objectivec_helpers.cc:501
testing::gtest_printers_test::Print
std::string Print(const T &value)
Definition: googletest-printers-test.cc:233
google::protobuf::compiler::objectivec::ExtensionMethodName
string ExtensionMethodName(const FieldDescriptor *descriptor)
Definition: objectivec_helpers.cc:532
google::protobuf::compiler::annotation_test_util::AddFile
void AddFile(const std::string &filename, const std::string &data)
Definition: annotation_test_util.cc:72
strings
GLsizei const GLchar *const * strings
Definition: glcorearb.h:4046
google::protobuf::compiler::objectivec::ImportWriter::protobuf_framework_imports_
std::vector< string > protobuf_framework_imports_
Definition: objectivec_helpers.h:304
google::protobuf::compiler::objectivec::UnCamelCaseFieldName
string UnCamelCaseFieldName(const string &name, const FieldDescriptor *field)
Definition: objectivec_helpers.cc:587
google::protobuf::compiler::objectivec::Options
Definition: objectivec_helpers.h:50
google::protobuf::OneofDescriptor
Definition: src/google/protobuf/descriptor.h:843
string
GLsizei const GLchar *const * string
Definition: glcorearb.h:3083
google::protobuf::SourceLocation
Definition: src/google/protobuf/descriptor.h:145
google::protobuf::compiler::objectivec::BuildCommentsString
string BuildCommentsString(const SourceLocation &location, bool prefer_single_line)
Definition: objectivec_helpers.cc:928
descriptor
Descriptor * descriptor
Definition: php/ext/google/protobuf/protobuf.h:936
google::protobuf::compiler::objectivec::OneofName
string OneofName(const OneofDescriptor *descriptor)
Definition: objectivec_helpers.cc:571
google::protobuf::FileDescriptor::syntax
Syntax syntax() const
Definition: src/google/protobuf/descriptor.h:2175
google::protobuf::compiler::objectivec::ImportWriter::named_framework_to_proto_path_mappings_path_
const string named_framework_to_proto_path_mappings_path_
Definition: objectivec_helpers.h:299
google::protobuf::compiler::objectivec::HasNonZeroDefaultValue
bool HasNonZeroDefaultValue(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:865
google::protobuf::compiler::objectivec::ImportWriter::other_imports_
std::vector< string > other_imports_
Definition: objectivec_helpers.h:307
google::protobuf::compiler::objectivec::FileClassPrefix
string FileClassPrefix(const FileDescriptor *file)
Definition: objectivec_helpers.cc:398
google::protobuf::compiler::objectivec::DefaultValue
string DefaultValue(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:794
google::protobuf::compiler::objectivec::FilePath
string FilePath(const FileDescriptor *file)
Definition: objectivec_helpers.cc:404
google::protobuf::int32
int32_t int32
Definition: protobuf/src/google/protobuf/stubs/port.h:150
google::protobuf::compiler::objectivec::StripProto
string StripProto(const string &filename)
Definition: objectivec_helpers.cc:359
google::protobuf::compiler::objectivec::LineConsumer
Definition: objectivec_helpers.h:261
google::protobuf::compiler::objectivec::FLAGTYPE_EXTENSION
@ FLAGTYPE_EXTENSION
Definition: objectivec_helpers.h:153
google::protobuf::compiler::objectivec::EnumValueName
string EnumValueName(const EnumValueDescriptor *descriptor)
Definition: objectivec_helpers.cc:486
google::protobuf::compiler::objectivec::ImportWriter::need_to_parse_mapping_file_
bool need_to_parse_mapping_file_
Definition: objectivec_helpers.h:302
google::protobuf::compiler::objectivec::IsMapEntryMessage
bool IsMapEntryMessage(const Descriptor *descriptor)
Definition: objectivec_helpers.h:129
google::protobuf::compiler::objectivec::IsPrimitiveType
bool IsPrimitiveType(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:714
path
GLsizei const GLchar ** path
Definition: glcorearb.h:3658
google::protobuf::compiler::objectivec::Options::expected_prefixes_suppressions
std::vector< string > expected_prefixes_suppressions
Definition: objectivec_helpers.h:53
google::protobuf::compiler::objectivec::IsInitName
bool IsInitName(const string &name)
Definition: objectivec_helpers.cc:386
google::protobuf::compiler::objectivec::GetOptionalDeprecatedAttribute
string GetOptionalDeprecatedAttribute(const TDescriptor *descriptor, const FileDescriptor *file=NULL, bool preSpace=true, bool postNewline=false)
Definition: objectivec_helpers.h:158
google::protobuf::compiler::objectivec::FlagType
FlagType
Definition: objectivec_helpers.h:151
google::protobuf::StringPiece
Definition: stringpiece.h:180
google::protobuf::compiler::objectivec::BuildFlagsString
string BuildFlagsString(const FlagType flag_type, const std::vector< string > &strings)
Definition: objectivec_helpers.cc:910
google::protobuf::compiler::objectivec::ClassName
string ClassName(const Descriptor *descriptor)
Definition: objectivec_helpers.cc:460
google::protobuf::compiler::objectivec::GPBGenericValueFieldName
string GPBGenericValueFieldName(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:754
google::protobuf::compiler::objectivec::GetCapitalizedType
string GetCapitalizedType(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:619
google::protobuf::compiler::objectivec::TrimWhitespace
void TrimWhitespace(StringPiece *input)
Definition: objectivec_helpers.cc:367
google::protobuf::compiler::objectivec::Options::expected_prefixes_path
string expected_prefixes_path
Definition: objectivec_helpers.h:52
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_INT64
@ OBJECTIVECTYPE_INT64
Definition: objectivec_helpers.h:140
google::protobuf::compiler::objectivec::ImportWriter::proto_file_to_framework_name_
std::map< string, string > proto_file_to_framework_name_
Definition: objectivec_helpers.h:301
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_ENUM
@ OBJECTIVECTYPE_ENUM
Definition: objectivec_helpers.h:147
google::protobuf::compiler::objectivec::FieldName
string FieldName(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:538
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_FLOAT
@ OBJECTIVECTYPE_FLOAT
Definition: objectivec_helpers.h:142
google::protobuf::FileDescriptor::SYNTAX_PROTO3
@ SYNTAX_PROTO3
Definition: src/google/protobuf/descriptor.h:1394
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_DATA
@ OBJECTIVECTYPE_DATA
Definition: objectivec_helpers.h:146
google::protobuf::compiler::objectivec::FieldNameCapitalized
string FieldNameCapitalized(const FieldDescriptor *field)
Definition: objectivec_helpers.cc:553
google::protobuf::compiler::objectivec::TextFormatDecodeData::entries_
std::vector< DataEntry > entries_
Definition: objectivec_helpers.h:257
google::protobuf::compiler::objectivec::ImportWriter::protobuf_non_framework_imports_
std::vector< string > protobuf_non_framework_imports_
Definition: objectivec_helpers.h:305
field
const FieldDescriptor * field
Definition: parser_unittest.cc:2694
google::protobuf::compiler::objectivec::ImportWriter::ProtoFrameworkCollector::ProtoFrameworkCollector
ProtoFrameworkCollector(std::map< string, string > *inout_proto_file_to_framework_name)
Definition: objectivec_helpers.h:287
key
const SETUP_TEARDOWN_TESTCONTEXT char * key
Definition: test_wss_transport.cpp:10
google::protobuf::compiler::objectivec::ValidateObjCClassPrefixes
bool ValidateObjCClassPrefixes(const std::vector< const FileDescriptor * > &files, const Options &generation_options, string *out_error)
Definition: objectivec_helpers.cc:1202
google::protobuf::compiler::objectivec::TextFormatDecodeData::DataEntry
std::pair< int32, string > DataEntry
Definition: objectivec_helpers.h:256
location
GLint location
Definition: glcorearb.h:3074
google::protobuf::io::Printer
Definition: printer.h:181
google::protobuf::compiler::objectivec::UnCamelCaseEnumShortName
string UnCamelCaseEnumShortName(const string &name)
Definition: objectivec_helpers.cc:520
google::protobuf::FileDescriptor::name
const std::string & name() const
google::protobuf::compiler::objectivec::ImportWriter::ProtoFrameworkCollector
Definition: objectivec_helpers.h:285
type
GLenum type
Definition: glcorearb.h:2695
google::protobuf::compiler::objectivec::ProtobufFrameworkImportSymbol
string ProtobufFrameworkImportSymbol(const string &framework_name)
Definition: objectivec_helpers.cc:986
google::protobuf::compiler::objectivec::ObjectiveCType
ObjectiveCType
Definition: objectivec_helpers.h:137
google::protobuf::compiler::objectivec::OneofEnumName
string OneofEnumName(const OneofDescriptor *descriptor)
Definition: objectivec_helpers.cc:563
google::protobuf::compiler::objectivec::TextFormatDecodeData::num_entries
size_t num_entries() const
Definition: objectivec_helpers.h:249
google::protobuf::compiler::objectivec::FLAGTYPE_FIELD
@ FLAGTYPE_FIELD
Definition: objectivec_helpers.h:154
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_MESSAGE
@ OBJECTIVECTYPE_MESSAGE
Definition: objectivec_helpers.h:148
google::protobuf::compiler::objectivec::FilePathBasename
string FilePathBasename(const FileDescriptor *file)
Definition: objectivec_helpers.cc:421
google::protobuf::EnumValueDescriptor
Definition: src/google/protobuf/descriptor.h:1075
google::protobuf::Descriptor
Definition: src/google/protobuf/descriptor.h:231
descriptor.h
google::protobuf::compiler::objectivec::IsRetainedName
bool IsRetainedName(const string &name)
Definition: objectivec_helpers.cc:377
google::protobuf::FileDescriptor
Definition: src/google/protobuf/descriptor.h:1320
google::protobuf::compiler::objectivec::IsProtobufLibraryBundledProtoFile
bool IsProtobufLibraryBundledProtoFile(const FileDescriptor *file)
Definition: objectivec_helpers.cc:994
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_DOUBLE
@ OBJECTIVECTYPE_DOUBLE
Definition: objectivec_helpers.h:143
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_UINT64
@ OBJECTIVECTYPE_UINT64
Definition: objectivec_helpers.h:141
descriptor.pb.h
google::protobuf::compiler::objectivec::EnumName
string EnumName(const EnumDescriptor *descriptor)
Definition: objectivec_helpers.cc:472
google::protobuf::compiler::objectivec::ImportWriter::include_wkt_imports_
const bool include_wkt_imports_
Definition: objectivec_helpers.h:300
google::protobuf::compiler::objectivec::FileClassName
string FileClassName(const FileDescriptor *file)
Definition: objectivec_helpers.cc:434
google::protobuf::EnumDescriptor
Definition: src/google/protobuf/descriptor.h:918
google::protobuf::compiler::objectivec::GetObjectiveCType
ObjectiveCType GetObjectiveCType(FieldDescriptor::Type field_type)
Definition: objectivec_helpers.cc:665
google::protobuf::compiler::objectivec::OBJECTIVECTYPE_BOOLEAN
@ OBJECTIVECTYPE_BOOLEAN
Definition: objectivec_helpers.h:144
google::protobuf::compiler::objectivec::EscapeTrigraphs
string EscapeTrigraphs(const string &to_escape)
Definition: objectivec_helpers.cc:355
compiler
Definition: plugin.pb.cc:22
google
Definition: data_proto2_to_proto3_util.h:11
message
GLenum GLuint GLenum GLsizei const GLchar * message
Definition: glcorearb.h:2695
google::protobuf::compiler::objectivec::FLAGTYPE_DESCRIPTOR_INITIALIZATION
@ FLAGTYPE_DESCRIPTOR_INITIALIZATION
Definition: objectivec_helpers.h:152
google::protobuf::compiler::objectivec::Options::Options
Options()
Definition: objectivec_helpers.cc:72


libaditof
Author(s):
autogenerated on Wed May 21 2025 02:06:57