Home
last modified time | relevance | path

Searched refs:enum_type (Results 1 – 25 of 104) sorted by relevance

12345

/third_party/protobuf/benchmarks/util/
Dschema_proto2_to_proto3_util.h94 void ScrubEnum(EnumDescriptorProto *enum_type) { in ScrubEnum() argument
95 if (enum_type->value(0).number() != 0) { in ScrubEnum()
97 for (int j = 0; j < enum_type->value().size(); j++) { in ScrubEnum()
98 if (enum_type->value(j).number() == 0) { in ScrubEnum()
100 temp_enum_value.CopyFrom(enum_type->value(j)); in ScrubEnum()
101 enum_type->mutable_value(j)->CopyFrom(enum_type->value(0)); in ScrubEnum()
102 enum_type->mutable_value(0)->CopyFrom(temp_enum_value); in ScrubEnum()
108 enum_type->mutable_value()->Add(); in ScrubEnum()
109 for (int i = enum_type->mutable_value()->size() - 1; i > 0; i--) { in ScrubEnum()
110 enum_type->mutable_value(i)->CopyFrom( in ScrubEnum()
[all …]
/third_party/protobuf/src/google/protobuf/util/internal/
Dutility.cc195 const google::protobuf::Enum* enum_type, StringPiece enum_name) { in FindEnumValueByNameOrNull() argument
196 if (enum_type != nullptr) { in FindEnumValueByNameOrNull()
197 for (int i = 0; i < enum_type->enumvalue_size(); ++i) { in FindEnumValueByNameOrNull()
198 const google::protobuf::EnumValue& enum_value = enum_type->enumvalue(i); in FindEnumValueByNameOrNull()
208 const google::protobuf::Enum* enum_type, int32 value) { in FindEnumValueByNumberOrNull() argument
209 if (enum_type != nullptr) { in FindEnumValueByNumberOrNull()
210 for (int i = 0; i < enum_type->enumvalue_size(); ++i) { in FindEnumValueByNumberOrNull()
211 const google::protobuf::EnumValue& enum_value = enum_type->enumvalue(i); in FindEnumValueByNumberOrNull()
221 const google::protobuf::Enum* enum_type, StringPiece enum_name) { in FindEnumValueByNameWithoutUnderscoreOrNull() argument
222 if (enum_type != nullptr) { in FindEnumValueByNameWithoutUnderscoreOrNull()
[all …]
Ddatapiece.cc274 StatusOr<int> DataPiece::ToEnum(const google::protobuf::Enum* enum_type, in ToEnum() argument
285 FindEnumValueByNameOrNull(enum_type, enum_name); in ToEnum()
292 FindEnumValueByNumberOrNull(enum_type, int_value.value())) { in ToEnum()
305 value = FindEnumValueByNameOrNull(enum_type, enum_name); in ToEnum()
313 value = FindEnumValueByNameWithoutUnderscoreOrNull(enum_type, enum_name); in ToEnum()
320 if (enum_type->enumvalue_size() > 0) { in ToEnum()
321 return enum_type->enumvalue(0).number(); in ToEnum()
Dutility.h135 const google::protobuf::Enum* enum_type, StringPiece enum_name);
140 const google::protobuf::Enum* enum_type, int32 value);
147 const google::protobuf::Enum* enum_type, StringPiece enum_name);
Dtype_info.cc98 std::unique_ptr<google::protobuf::Enum> enum_type( in GetEnumByTypeUrl() local
101 type_resolver_->ResolveEnumType(string_type_url, enum_type.get()); in GetEnumByTypeUrl()
103 status.ok() ? StatusOrEnum(enum_type.release()) : StatusOrEnum(status); in GetEnumByTypeUrl()
/third_party/protobuf/python/google/protobuf/
Ddescriptor_database.py77 for enum in file_desc_proto.enum_type:
176 for enum_type in desc_proto.enum_type:
177 yield '.'.join((message_name, enum_type.name))
Ddescriptor_pool.py775 for enum_type in file_proto.enum_type:
776 file_descriptor.enum_types_by_name[enum_type.name] = (
777 self._ConvertEnumDescriptor(enum_type, file_proto.package,
859 for enum in desc_proto.enum_type]
998 enum_type=None,
1070 field_desc.enum_type = desc
1085 field_desc.default_value = field_desc.enum_type.values_by_name[
1105 field_desc.default_value = field_desc.enum_type.values[0].number
Ddescriptor.py339 for enum_type in self.enum_types:
340 enum_type.containing_type = self
537 default_value, message_type, enum_type, containing_type, argument
549 default_value, message_type, enum_type, containing_type, argument
583 self.enum_type = enum_type
1088 for enum_proto in desc_proto.enum_type:
/third_party/protobuf/php/src/Google/Protobuf/Internal/
DFileDescriptor.php40 private $enum_type = []; variable in Google\\Protobuf\\Internal\\FileDescriptor
64 return $this->enum_type;
69 $this->enum_type[]= $desc;
DFieldDescriptor.php47 private $enum_type; variable in Google\\Protobuf\\Internal\\FieldDescriptor
152 public function setEnumType($enum_type) argument
154 $this->enum_type = $enum_type;
159 return $this->enum_type;
DDescriptor.php45 private $enum_type = []; variable in Google\\Protobuf\\Internal\\Descriptor
101 $this->enum_type[] = $desc;
106 return $this->enum_type;
DDescriptorProto.php39 private $enum_type; variable in Google\\Protobuf\\Internal\\DescriptorProto
193 return $this->enum_type;
204 $this->enum_type = $arr;
DFileDescriptorProto.php60 private $enum_type; variable in Google\\Protobuf\\Internal\\FileDescriptorProto
312 return $this->enum_type;
323 $this->enum_type = $arr;
/third_party/protobuf/src/google/protobuf/util/
Dtype_resolver_util.cc93 Enum* enum_type) override { in ResolveEnumType() argument
105 ConvertEnumDescriptor(descriptor, enum_type); in ResolveEnumType()
269 field->set_type_url(GetTypeUrl(descriptor->enum_type())); in ConvertFieldDescriptor()
282 Enum* enum_type) { in ConvertEnumDescriptor() argument
283 enum_type->Clear(); in ConvertEnumDescriptor()
284 enum_type->set_name(descriptor->full_name()); in ConvertEnumDescriptor()
285 enum_type->mutable_source_context()->set_file_name( in ConvertEnumDescriptor()
289 EnumValue* value = enum_type->mutable_enumvalue()->Add(); in ConvertEnumDescriptor()
297 ConvertEnumOptions(descriptor->options(), enum_type->mutable_options()); in ConvertEnumDescriptor()
/third_party/protobuf/python/google/protobuf/internal/
Denum_type_wrapper.py48 def __init__(self, enum_type): argument
50 self._enum_type = enum_type
51 self.DESCRIPTOR = enum_type # pylint: disable=invalid-name
/third_party/mesa3d/src/vulkan/util/
Dgen_enum_to_str.py374 for enum_type in xml.findall('./enums[@type="enum"]'):
375 enum = enum_factory(enum_type.attrib['name'])
376 for value in enum_type.findall('./enum'):
380 for enum_type in xml.findall('./enums[@type="bitmask"]'):
381 bitwidth = int(enum_type.attrib.get('bitwidth', 32))
382 enum = bitmask_factory(enum_type.attrib['name'], bitwidth=bitwidth)
383 for value in enum_type.findall('./enum'):
/third_party/protobuf/src/google/protobuf/compiler/objectivec/
Dobjectivec_enum_field.cc48 string type = EnumName(descriptor->enum_type()); in SetEnumVariables()
54 (descriptor->file() != descriptor->enum_type()->file())) { in SetEnumVariables()
124 if (descriptor_->file() != descriptor_->enum_type()->file()) { in DetermineForwardDeclarations()
/third_party/gstreamer/gstplugins_base/tests/examples/gl/gtk/3dvideo/
Dmviewwidget.c51 static GtkWidget *combo_box_from_enum (GType enum_type);
138 enum_value_to_nick (GType enum_type, guint value) in enum_value_to_nick() argument
144 enum_info = (GEnumClass *) (g_type_class_ref (enum_type)); in enum_value_to_nick()
293 combo_box_from_enum (GType enum_type) in combo_box_from_enum() argument
299 enum_info = (GEnumClass *) (g_type_class_ref (enum_type)); in combo_box_from_enum()
/third_party/protobuf/src/google/protobuf/compiler/ruby/
Druby_generator.cc193 "subtype", value_field->enum_type()->full_name()); in GenerateField()
215 "subtype", field->enum_type()->full_name()); in GenerateField()
281 GenerateEnum(message->enum_type(i), printer); in GenerateMessage()
387 GenerateEnumAssignment(nested_prefix, message->enum_type(i), printer); in GenerateMessageAssignment()
471 field->enum_type()->file() == file)) { in UsesTypeFromFile()
562 GenerateEnum(file->enum_type(i), printer); in GenerateFile()
575 GenerateEnumAssignment("", file->enum_type(i), printer); in GenerateFile()
/third_party/protobuf/src/google/protobuf/compiler/
Dparser_unittest.cc3104 EXPECT_TRUE(HasSpan('a', 'd', file_.enum_type(0))); in TEST_F()
3105 EXPECT_TRUE(HasSpan('b', 'c', file_.enum_type(0), "name")); in TEST_F()
3106 EXPECT_TRUE(HasSpan('e', 'h', file_.enum_type(1))); in TEST_F()
3107 EXPECT_TRUE(HasSpan('f', 'g', file_.enum_type(1), "name")); in TEST_F()
3120 const EnumValueDescriptorProto& bar = file_.enum_type(0).value(0); in TEST_F()
3121 const EnumValueDescriptorProto& baz = file_.enum_type(0).value(1); in TEST_F()
3132 EXPECT_TRUE(HasSpan(file_.enum_type(0))); in TEST_F()
3133 EXPECT_TRUE(HasSpan(file_.enum_type(0), "name")); in TEST_F()
3143 const EnumDescriptorProto& bar = file_.message_type(0).enum_type(0); in TEST_F()
3144 const EnumDescriptorProto& baz = file_.message_type(0).enum_type(1); in TEST_F()
[all …]
/third_party/skia/third_party/externals/angle2/src/common/
Dgen_packed_gl_enums.py271 enum_type = generator['enum_type']
274 namespace, enum_type)
276 enum_type)
/third_party/skia/third_party/externals/angle2/src/compiler/translator/
Dgen_emulated_builtin_function_tables.py80 def enum_type(arg): function
105 func += "BuiltInId::" + data['op'] + "_" + "_".join([enum_type(arg) for arg in data['args']
/third_party/protobuf/src/google/protobuf/compiler/java/
Djava_file.cc323 EnumGenerator(file_->enum_type(i), immutable_api_, context_.get()) in Generate()
326 EnumLiteGenerator(file_->enum_type(i), immutable_api_, context_.get()) in Generate()
641 EnumGenerator generator(file_->enum_type(i), immutable_api_, in GenerateSiblings()
644 package_dir, java_package_, file_->enum_type(i), context, file_list, in GenerateSiblings()
648 EnumLiteGenerator generator(file_->enum_type(i), immutable_api_, in GenerateSiblings()
651 package_dir, java_package_, file_->enum_type(i), context, file_list, in GenerateSiblings()
/third_party/protobuf/src/google/protobuf/compiler/python/
Dpython_generator.cc492 const EnumDescriptor& enum_descriptor = *file_->enum_type(i); in PrintTopLevelEnums()
579 PrintEnum(*descriptor.enum_type(i)); in PrintNestedEnums()
765 ModuleLevelDescriptorName(*message_descriptor.enum_type(i)); in PrintDescriptor()
934 const EnumDescriptor& enum_descriptor = *descriptor.enum_type(i); in FixForeignFieldsInDescriptor()
1024 const EnumDescriptor* enum_type = field.enum_type(); in FixForeignFieldsInField() local
1025 if (enum_type) { in FixForeignFieldsInField()
1026 m["enum_type"] = ModuleLevelDescriptorName(*enum_type); in FixForeignFieldsInField()
1081 AddEnumToFileDescriptor(*file_->enum_type(i)); in FixForeignFieldsInDescriptors()
1347 const EnumDescriptor& enum_descriptor = *file_->enum_type(i); in FixAllDescriptorOptions()
1429 FixOptionsForEnum(*descriptor.enum_type(i)); in FixOptionsForMessage()
/third_party/protobuf/src/google/protobuf/compiler/cpp/
Dcpp_extension.cc70 type_traits_.append(ClassName(descriptor_->enum_type(), true)); in ExtensionGenerator()
72 type_traits_.append(ClassName(descriptor_->enum_type(), true)); in ExtensionGenerator()

12345