Go to the documentation of this file.
42 namespace objectivec {
74 "typedef GPB_ENUM($enum_name$) {\n");
78 "$enum_name$_GPBUnsetOneOfCase = 0,\n");
84 "$enum_name$_$field_name$ = $field_number$,\n",
85 "enum_name", enum_name,
86 "field_name", field_name,
100 "@property(nonatomic, readonly) $enum_name$ $name$OneOfCase;\n"
108 " * Clears whatever value was set for the oneof '$name$'.\n"
110 "void $owning_message_class$_Clear$capitalized_name$OneOfCase($owning_message_class$ *message);\n");
116 "@dynamic $name$OneOfCase;\n");
122 "void $owning_message_class$_Clear$capitalized_name$OneOfCase($owning_message_class$ *message) {\n"
123 " GPBDescriptor *descriptor = [message descriptor];\n"
124 " GPBOneofDescriptor *oneof = [descriptor.oneofs objectAtIndex:$raw_index$];\n"
125 " GPBMaybeClearOneof(message, oneof, $index$, 0);\n"
void Print(const std::map< std::string, std::string > &variables, const char *text)
string OneofNameCapitalized(const OneofDescriptor *descriptor)
string StrCat(const AlphaNum &a, const AlphaNum &b)
void GenerateClearFunctionDeclaration(io::Printer *printer)
void GeneratePropertyImplementation(io::Printer *printer)
string BuildCommentsString(const SourceLocation &location, bool prefer_single_line)
const FieldDescriptor * field(int index) const
string OneofName(const OneofDescriptor *descriptor)
string ClassName(const Descriptor *descriptor)
bool GetSourceLocation(SourceLocation *out_location) const
string DescriptorName(void) const
string FieldNameCapitalized(const FieldDescriptor *field)
OneofGenerator(const OneofDescriptor *descriptor)
const FieldDescriptor * field
const OneofDescriptor * descriptor_
string HasIndexAsString(void) const
string OneofEnumName(const OneofDescriptor *descriptor)
std::map< string, string > variables_
void SetOneofIndexBase(int index_base)
void GenerateCaseEnum(io::Printer *printer)
void GenerateClearFunctionImplementation(io::Printer *printer)
void GeneratePublicCasePropertyDeclaration(io::Printer *printer)
const Descriptor * descriptor_
const Descriptor * containing_type() const
libaditof
Author(s):
autogenerated on Wed May 21 2025 02:06:57