Home
last modified time | relevance | path

Searched refs:descriptor_ (Results 1 – 25 of 105) sorted by relevance

12345

/third_party/protobuf/src/google/protobuf/compiler/java/
Djava_enum_field_lite.cc128 : descriptor_(descriptor), in ImmutableEnumFieldLiteGenerator()
140 return SupportFieldPresence(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
145 if (SupportFieldPresence(descriptor_)) { in GenerateInterfaceMembers()
146 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
150 if (SupportUnknownEnumValue(descriptor_->file())) { in GenerateInterfaceMembers()
151 WriteFieldEnumValueAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
155 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
163 if (SupportFieldPresence(descriptor_)) { in GenerateMembers()
164 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
171 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
[all …]
Djava_message_field_lite.cc108 : descriptor_(descriptor), in ImmutableMessageFieldLiteGenerator()
123 return HasHasbit(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
128 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
130 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
140 if (HasHasbit(descriptor_)) { in GenerateMembers()
141 WriteFieldDocComment(printer, descriptor_); in GenerateMembers()
148 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
149 WriteFieldDocComment(printer, descriptor_); in GenerateMembers()
156 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
158 WriteFieldDocComment(printer, descriptor_); in GenerateMembers()
[all …]
Djava_map_field_lite.cc143 : descriptor_(descriptor), in ImmutableMapFieldLiteGenerator()
157 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
160 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
161 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
165 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
166 if (GetJavaType(ValueField(descriptor_)) == JAVATYPE_ENUM) { in GenerateInterfaceMembers()
174 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
175 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
180 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
181 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
[all …]
Djava_string_field_lite.cc119 : descriptor_(descriptor), in ImmutableStringFieldLiteGenerator()
130 return SupportFieldPresence(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
160 if (SupportFieldPresence(descriptor_)) { in GenerateInterfaceMembers()
161 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
165 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
168 WriteFieldStringBytesAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
179 if (SupportFieldPresence(descriptor_)) { in GenerateMembers()
180 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
187 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
190 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateMembers()
[all …]
Djava_enum_field.cc139 : descriptor_(descriptor), name_resolver_(context->GetNameResolver()) { in ImmutableEnumFieldGenerator()
148 return SupportFieldPresence(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
157 if (SupportFieldPresence(descriptor_)) { in GenerateInterfaceMembers()
158 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
162 if (SupportUnknownEnumValue(descriptor_->file())) { in GenerateInterfaceMembers()
163 WriteFieldEnumValueAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
167 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
174 if (SupportFieldPresence(descriptor_)) { in GenerateMembers()
175 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
181 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
[all …]
Djava_primitive_field_lite.cc180 : descriptor_(descriptor), in ImmutablePrimitiveFieldLiteGenerator()
191 return SupportFieldPresence(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
196 if (SupportFieldPresence(descriptor_)) { in GenerateInterfaceMembers()
197 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
201 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
207 if (IsByteStringWithCustomDefaultValue(descriptor_)) { in GenerateMembers()
216 if (SupportFieldPresence(descriptor_)) { in GenerateMembers()
217 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
224 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
227 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateMembers()
[all …]
Djava_message_lite.cc76 for (int i = 0; i < descriptor_->field_count(); i++) { in ImmutableMessageLiteGenerator()
77 if (IsRealOneof(descriptor_->field(i))) { in ImmutableMessageLiteGenerator()
78 oneofs_.insert(descriptor_->field(i)->containing_oneof()); in ImmutableMessageLiteGenerator()
88 for (int i = 0; i < descriptor_->nested_type_count(); i++) { in GenerateStaticVariables()
90 ImmutableMessageLiteGenerator(descriptor_->nested_type(i), context_) in GenerateStaticVariables()
99 for (int i = 0; i < descriptor_->nested_type_count(); i++) { in GenerateStaticVariableInitializers()
102 ImmutableMessageLiteGenerator(descriptor_->nested_type(i), context_) in GenerateStaticVariableInitializers()
111 MaybePrintGeneratedAnnotation(context_, printer, descriptor_, in GenerateInterface()
113 if (descriptor_->extension_range_count() > 0) { in GenerateInterface()
121 descriptor_->options().deprecated() ? "@java.lang.Deprecated " : "", in GenerateInterface()
[all …]
Djava_map_field.cc162 : descriptor_(descriptor), name_resolver_(context->GetNameResolver()) { in ImmutableMapFieldGenerator()
176 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
179 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
180 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
184 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
185 if (GetJavaType(ValueField(descriptor_)) == JAVATYPE_ENUM) { in GenerateInterfaceMembers()
193 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
194 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
199 printer->Annotate("{", "}", descriptor_); in GenerateInterfaceMembers()
200 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
[all …]
Djava_message_field.cc125 : descriptor_(descriptor), name_resolver_(context->GetNameResolver()) { in ImmutableMessageFieldGenerator()
134 return HasHasbit(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
147 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
149 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
152 WriteFieldDocComment(printer, descriptor_); in GenerateInterfaceMembers()
163 if (HasHasbit(descriptor_)) { in GenerateMembers()
164 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
171 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
172 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateMembers()
179 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
[all …]
Djava_string_field.cc141 : descriptor_(descriptor), name_resolver_(context->GetNameResolver()) { in ImmutableStringFieldGenerator()
150 return SupportFieldPresence(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
191 if (SupportFieldPresence(descriptor_)) { in GenerateInterfaceMembers()
192 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
196 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
199 WriteFieldStringBytesAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
210 if (SupportFieldPresence(descriptor_)) { in GenerateMembers()
211 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
218 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
221 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateMembers()
[all …]
Djava_message.cc78 : descriptor_(descriptor) { in MessageGenerator()
79 for (int i = 0; i < descriptor_->field_count(); i++) { in MessageGenerator()
80 if (IsRealOneof(descriptor_->field(i))) { in MessageGenerator()
81 oneofs_.insert(descriptor_->field(i)->containing_oneof()); in MessageGenerator()
112 vars["identifier"] = UniqueFileScopeIdentifier(descriptor_); in GenerateStaticVariables()
113 vars["index"] = StrCat(descriptor_->index()); in GenerateStaticVariables()
114 vars["classname"] = name_resolver_->GetImmutableClassName(descriptor_); in GenerateStaticVariables()
115 if (descriptor_->containing_type() != NULL) { in GenerateStaticVariables()
116 vars["parent"] = UniqueFileScopeIdentifier(descriptor_->containing_type()); in GenerateStaticVariables()
118 if (MultipleJavaFiles(descriptor_->file(), /* immutable = */ true)) { in GenerateStaticVariables()
[all …]
Djava_enum.cc54 : descriptor_(descriptor), in EnumGenerator()
58 for (int i = 0; i < descriptor_->value_count(); i++) { in EnumGenerator()
59 const EnumValueDescriptor* value = descriptor_->value(i); in EnumGenerator()
61 descriptor_->FindValueByNumber(value->number()); in EnumGenerator()
77 WriteEnumDocComment(printer, descriptor_); in Generate()
78 MaybePrintGeneratedAnnotation(context_, printer, descriptor_, immutable_api_); in Generate()
82 "classname", descriptor_->name()); in Generate()
83 printer->Annotate("classname", descriptor_); in Generate()
113 if (SupportUnknownEnumValue(descriptor_->file())) { in Generate()
119 printer->Annotate("{", "}", descriptor_); in Generate()
[all …]
Djava_primitive_field.cc189 : descriptor_(descriptor), name_resolver_(context->GetNameResolver()) { in ImmutablePrimitiveFieldGenerator()
198 return SupportFieldPresence(descriptor_) ? 1 : 0; in GetNumBitsForMessage()
207 if (SupportFieldPresence(descriptor_)) { in GenerateInterfaceMembers()
208 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateInterfaceMembers()
212 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateInterfaceMembers()
220 if (SupportFieldPresence(descriptor_)) { in GenerateMembers()
221 WriteFieldAccessorDocComment(printer, descriptor_, HAZZER); in GenerateMembers()
228 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
231 WriteFieldAccessorDocComment(printer, descriptor_, GETTER); in GenerateMembers()
237 printer->Annotate("{", "}", descriptor_); in GenerateMembers()
[all …]
Djava_message_builder.cc72 : descriptor_(descriptor), in MessageBuilderGenerator()
79 for (int i = 0; i < descriptor_->field_count(); i++) { in MessageBuilderGenerator()
80 if (IsRealOneof(descriptor_->field(i))) { in MessageBuilderGenerator()
81 oneofs_.insert(descriptor_->field(i)->containing_oneof()); in MessageBuilderGenerator()
89 WriteMessageDocComment(printer, descriptor_); in Generate()
90 if (descriptor_->extension_range_count() > 0) { in Generate()
97 "classname", name_resolver_->GetImmutableClassName(descriptor_), in Generate()
98 "extra_interfaces", ExtraBuilderInterfaces(descriptor_), "ver", in Generate()
107 "classname", name_resolver_->GetImmutableClassName(descriptor_), in Generate()
108 "extra_interfaces", ExtraBuilderInterfaces(descriptor_), "ver", in Generate()
[all …]
Djava_enum_lite.cc55 : descriptor_(descriptor), in EnumLiteGenerator()
59 for (int i = 0; i < descriptor_->value_count(); i++) { in EnumLiteGenerator()
60 const EnumValueDescriptor* value = descriptor_->value(i); in EnumLiteGenerator()
62 descriptor_->FindValueByNumber(value->number()); in EnumLiteGenerator()
78 WriteEnumDocComment(printer, descriptor_); in Generate()
79 MaybePrintGeneratedAnnotation(context_, printer, descriptor_, immutable_api_); in Generate()
83 "classname", descriptor_->name()); in Generate()
84 printer->Annotate("classname", descriptor_); in Generate()
99 if (SupportUnknownEnumValue(descriptor_->file())) { in Generate()
101 printer->Annotate("{", "}", descriptor_); in Generate()
[all …]
Djava_service.cc50 : descriptor_(descriptor) {} in ServiceGenerator()
64 bool is_own_file = IsOwnFile(descriptor_, /* immutable = */ true); in Generate()
65 WriteServiceDocComment(printer, descriptor_); in Generate()
66 MaybePrintGeneratedAnnotation(context_, printer, descriptor_, in Generate()
71 "static", is_own_file ? "" : "static", "classname", descriptor_->name()); in Generate()
75 descriptor_->name()); in Generate()
91 "file", name_resolver_->GetImmutableClassName(descriptor_->file()), in Generate()
92 "index", StrCat(descriptor_->index())); in Generate()
106 "full_name", descriptor_->full_name()); in Generate()
135 "classname", descriptor_->name()); in GenerateNewReflectiveServiceMethod()
[all …]
/third_party/protobuf/src/google/protobuf/compiler/cpp/
Dcpp_enum.cc76 : descriptor_(descriptor), in EnumGenerator()
82 variables_["classtype"] = QualifiedClassName(descriptor_, options); in EnumGenerator()
83 variables_["short_name"] = descriptor_->name(); in EnumGenerator()
84 variables_["nested_name"] = descriptor_->name(); in EnumGenerator()
85 variables_["resolved_name"] = ResolveKeyword(descriptor_->name()); in EnumGenerator()
87 (descriptor_->containing_type() == NULL) ? "" : classname_ + "_"; in EnumGenerator()
94 format("enum ${1$$classname$$}$ : int {\n", descriptor_); in GenerateDefinition()
97 const EnumValueDescriptor* min_value = descriptor_->value(0); in GenerateDefinition()
98 const EnumValueDescriptor* max_value = descriptor_->value(0); in GenerateDefinition()
100 for (int i = 0; i < descriptor_->value_count(); i++) { in GenerateDefinition()
[all …]
Dcpp_message_field.cc107 if (!IsFieldUsed(descriptor_, options_)) { in GenerateAccessorDeclarations()
117 descriptor_); in GenerateAccessorDeclarations()
118 if (SupportsArenas(descriptor_)) { in GenerateAccessorDeclarations()
125 descriptor_); in GenerateAccessorDeclarations()
135 descriptor_); in GenerateAccessorDeclarations()
136 if (IsFieldUsed(descriptor_, options_)) { in GenerateAccessorDeclarations()
142 descriptor_); in GenerateAccessorDeclarations()
144 if (SupportsArenas(descriptor_)) { in GenerateAccessorDeclarations()
150 descriptor_); in GenerateAccessorDeclarations()
174 if (SupportsArenas(descriptor_)) { in GenerateInlineAccessorDefinitions()
[all …]
Dcpp_extension.cc61 : descriptor_(descriptor), options_(options) { in ExtensionGenerator()
63 if (descriptor_->is_repeated()) { in ExtensionGenerator()
67 switch (descriptor_->cpp_type()) { in ExtensionGenerator()
70 type_traits_.append(ClassName(descriptor_->enum_type(), true)); in ExtensionGenerator()
72 type_traits_.append(ClassName(descriptor_->enum_type(), true)); in ExtensionGenerator()
80 type_traits_.append(ClassName(descriptor_->message_type(), true)); in ExtensionGenerator()
85 type_traits_.append(PrimitiveTypeName(options_, descriptor_->cpp_type())); in ExtensionGenerator()
90 variables_["extendee"] = ExtendeeClassName(descriptor_); in ExtensionGenerator()
92 std::string name = descriptor_->name(); in ExtensionGenerator()
94 variables_["constant_name"] = FieldConstantName(descriptor_); in ExtensionGenerator()
[all …]
Dcpp_string_field.cc120 if (!descriptor_->default_value_string().empty()) { in GenerateStaticMembers()
151 bool unknown_ctype = descriptor_->options().ctype() != in GenerateAccessorDeclarations()
152 EffectiveStringCType(descriptor_, options_); in GenerateAccessorDeclarations()
167 descriptor_); in GenerateAccessorDeclarations()
171 descriptor_); in GenerateAccessorDeclarations()
181 descriptor_); in GenerateAccessorDeclarations()
215 if (SupportsArenas(descriptor_)) { in GenerateInlineAccessorDefinitions()
267 if (HasHasbit(descriptor_)) { in GenerateInlineAccessorDefinitions()
345 if (HasHasbit(descriptor_)) { in GenerateInlineAccessorDefinitions()
376 if (!descriptor_->default_value_string().empty()) { in GenerateNonInlineAccessorDefinitions()
[all …]
Dcpp_message.cc570 : descriptor_(descriptor), in MessageGenerator()
585 variables_["classtype"] = QualifiedClassName(descriptor_, options); in MessageGenerator()
587 SccInfoSymbol(scc_analyzer_->GetSCC(descriptor_), options_); in MessageGenerator()
588 variables_["full_name"] = descriptor_->full_name(); in MessageGenerator()
589 variables_["superclass"] = SuperClassName(descriptor_, options_); in MessageGenerator()
593 for (auto field : FieldRange(descriptor_)) { in MessageGenerator()
611 has_bit_indices_.resize(descriptor_->field_count(), kNoHasbit); in MessageGenerator()
628 table_driven_ = TableDrivenParsingEnabled(descriptor_, options_); in MessageGenerator()
664 for (int i = 0; i < descriptor_->enum_type_count(); i++) { in AddGenerators()
666 new EnumGenerator(descriptor_->enum_type(i), variables_, options_)); in AddGenerators()
[all …]
/third_party/protobuf/src/google/protobuf/compiler/csharp/
Dcsharp_field_base.cc58 int tag_size = internal::WireFormat::TagSize(descriptor_->number(), descriptor_->type()); in SetCommonFieldVariables()
60 if (descriptor_->type() == FieldDescriptor::TYPE_GROUP) { in SetCommonFieldVariables()
63 uint tag = internal::WireFormat::MakeTag(descriptor_); in SetCommonFieldVariables()
75 if (descriptor_->type() == FieldDescriptor::Type::TYPE_GROUP) { in SetCommonFieldVariables()
77 descriptor_->number(), in SetCommonFieldVariables()
93 (*variables)["extended_type"] = GetClassName(descriptor_->containing_type()); in SetCommonFieldVariables()
95 (*variables)["descriptor_name"] = descriptor_->name(); in SetCommonFieldVariables()
99 if (has_default_value() && !SupportsPresenceApi(descriptor_)) { in SetCommonFieldVariables()
105 if (SupportsPresenceApi(descriptor_)) { in SetCommonFieldVariables()
128 if (SupportsPresenceApi(descriptor_)) { in SetCommonOneofFieldVariables()
[all …]
Dcsharp_message.cc64 descriptor_(descriptor), in MessageGenerator()
69 for (int i = 0; i < descriptor_->field_count(); i++) { in MessageGenerator()
70 fields_by_number_.push_back(descriptor_->field(i)); in MessageGenerator()
76 for (int i = 0; i < descriptor_->field_count(); i++) { in MessageGenerator()
77 const FieldDescriptor* field = descriptor_->field(i); in MessageGenerator()
91 return descriptor_->name(); in class_name()
95 return GetClassName(descriptor_); in full_class_name()
103 if (descriptor_->options().deprecated()) { in AddDeprecatedFlag()
119 WriteMessageDocComment(printer, descriptor_); in Generate()
148 if (IsDescriptorProto(descriptor_->file())) { in Generate()
[all …]
/third_party/protobuf/src/google/protobuf/compiler/objectivec/
Dobjectivec_extension.cc48 descriptor_(descriptor) { in ExtensionGenerator()
70 if (descriptor_->GetSourceLocation(&location)) { in GenerateMembersHeader()
77 vars["deprecated_attribute"] = GetOptionalDeprecatedAttribute(descriptor_, descriptor_->file()); in GenerateMembersHeader()
87 const string containing_type = ClassName(descriptor_->containing_type()); in GenerateStaticVariablesInitialization()
89 vars["number"] = StrCat(descriptor_->number()); in GenerateStaticVariablesInitialization()
92 if (descriptor_->is_repeated()) options.push_back("GPBExtensionRepeated"); in GenerateStaticVariablesInitialization()
93 if (descriptor_->is_packed()) options.push_back("GPBExtensionPacked"); in GenerateStaticVariablesInitialization()
94 if (descriptor_->containing_type()->options().message_set_wire_format()) { in GenerateStaticVariablesInitialization()
99 ObjectiveCType objc_type = GetObjectiveCType(descriptor_); in GenerateStaticVariablesInitialization()
101 std::string message_type = ClassName(descriptor_->message_type()); in GenerateStaticVariablesInitialization()
[all …]
Dobjectivec_message.cc177 descriptor_(descriptor), in MessageGenerator()
179 class_name_(ClassName(descriptor_)), in MessageGenerator()
183 for (int i = 0; i < descriptor_->extension_count(); i++) { in MessageGenerator()
185 new ExtensionGenerator(class_name_, descriptor_->extension(i))); in MessageGenerator()
188 for (int i = 0; i < descriptor_->real_oneof_decl_count(); i++) { in MessageGenerator()
189 OneofGenerator* generator = new OneofGenerator(descriptor_->oneof_decl(i)); in MessageGenerator()
193 for (int i = 0; i < descriptor_->enum_type_count(); i++) { in MessageGenerator()
194 EnumGenerator* generator = new EnumGenerator(descriptor_->enum_type(i)); in MessageGenerator()
198 for (int i = 0; i < descriptor_->nested_type_count(); i++) { in MessageGenerator()
201 descriptor_->nested_type(i), in MessageGenerator()
[all …]

12345