Home
last modified time | relevance | path

Searched refs:field_descriptor (Results 1 – 18 of 18) sorted by relevance

/frameworks/opt/gamesdk/third_party/protobuf-3.0.0/python/google/protobuf/pyext/
Drepeated_scalar_container.cc91 const FieldDescriptor* field_descriptor = self->parent_field_descriptor; in AssignItem() local
94 int field_size = reflection->FieldSize(*message, field_descriptor); in AssignItem()
107 return cmessage::InternalDeleteRepeatedField(self->parent, field_descriptor, in AssignItem()
116 switch (field_descriptor->cpp_type()) { in AssignItem()
119 reflection->SetRepeatedInt32(message, field_descriptor, index, value); in AssignItem()
124 reflection->SetRepeatedInt64(message, field_descriptor, index, value); in AssignItem()
129 reflection->SetRepeatedUInt32(message, field_descriptor, index, value); in AssignItem()
134 reflection->SetRepeatedUInt64(message, field_descriptor, index, value); in AssignItem()
139 reflection->SetRepeatedFloat(message, field_descriptor, index, value); in AssignItem()
144 reflection->SetRepeatedDouble(message, field_descriptor, index, value); in AssignItem()
[all …]
Dmessage.cc109 PyObject* cls, const FieldDescriptor* field_descriptor) { in AddFieldNumberToClass() argument
110 string constant_name = field_descriptor->name() + "_FIELD_NUMBER"; in AddFieldNumberToClass()
117 ScopedPyObjectPtr number(PyInt_FromLong(field_descriptor->number())); in AddFieldNumberToClass()
413 const FieldDescriptor* field_descriptor,
433 const FieldDescriptor* field_descriptor) { in VisitCMessage()
742 bool CheckFieldBelongsToMessage(const FieldDescriptor* field_descriptor, in CheckAndGetInteger() argument
744 if (message->GetDescriptor() == field_descriptor->containing_type()) { in CheckAndGetInteger()
748 field_descriptor->full_name().c_str(), in CheckAndGetInteger()
900 const FieldDescriptor *field_descriptor = in CheckAndGetInteger() local
902 if (field_descriptor == NULL) { in CheckAndGetInteger()
[all …]
Dmessage.h162 const FieldDescriptor* field_descriptor,
174 CMessage* self, const FieldDescriptor* field_descriptor);
186 const FieldDescriptor* field_descriptor,
191 const FieldDescriptor* field_descriptor,
196 const FieldDescriptor* field_descriptor,
203 const FieldDescriptor* field_descriptor);
232 CMessage* self, const FieldDescriptor* field_descriptor);
282 #define FIELD_IS_REPEATED(field_descriptor) \ argument
283 ((field_descriptor)->label() == FieldDescriptor::LABEL_REPEATED)
356 bool CheckFieldBelongsToMessage(const FieldDescriptor* field_descriptor,
Dmap_container.cc132 const FieldDescriptor* field_descriptor, in PythonToMapKey() argument
134 switch (field_descriptor->cpp_type()) { in PythonToMapKey()
162 if (!PyStringToSTL(CheckString(obj, field_descriptor), &str)) { in PythonToMapKey()
171 field_descriptor->cpp_type()); in PythonToMapKey()
177 static PyObject* MapKeyToPython(const FieldDescriptor* field_descriptor, in MapKeyToPython() argument
179 switch (field_descriptor->cpp_type()) { in MapKeyToPython()
191 return ToStringObject(field_descriptor, key.GetStringValue()); in MapKeyToPython()
195 field_descriptor->cpp_type()); in MapKeyToPython()
202 PyObject* MapValueRefToPython(const FieldDescriptor* field_descriptor, in MapValueRefToPython() argument
204 switch (field_descriptor->cpp_type()) { in MapValueRefToPython()
[all …]
Ddescriptor_pool.cc246 const FieldDescriptor* field_descriptor = in FindFieldByName() local
248 if (field_descriptor == NULL) { in FindFieldByName()
254 return PyFieldDescriptor_FromDescriptor(field_descriptor); in FindFieldByName()
264 const FieldDescriptor* field_descriptor = in FindExtensionByName() local
266 if (field_descriptor == NULL) { in FindExtensionByName()
271 return PyFieldDescriptor_FromDescriptor(field_descriptor); in FindExtensionByName()
Ddescriptor.cc682 namespace field_descriptor { namespace
951 field_descriptor::Methods, // tp_methods
953 field_descriptor::Getters, // tp_getset
958 const FieldDescriptor* field_descriptor) { in PyFieldDescriptor_FromDescriptor() argument
960 &PyFieldDescriptor_Type, field_descriptor, NULL); in PyFieldDescriptor_FromDescriptor()
/frameworks/opt/gamesdk/third_party/protobuf-3.0.0/python/google/protobuf/internal/
Dpython_message.py284 def _AttachFieldHelpers(cls, field_descriptor): argument
285 is_repeated = (field_descriptor.label == _FieldDescriptor.LABEL_REPEATED)
287 wire_format.IsTypePackable(field_descriptor.type))
290 elif field_descriptor.containing_type.syntax == "proto2":
291 is_packed = (field_descriptor.has_options and
292 field_descriptor.GetOptions().packed)
294 has_packed_false = (field_descriptor.has_options and
295 field_descriptor.GetOptions().HasField("packed") and
296 field_descriptor.GetOptions().packed == False)
298 is_map_entry = _IsMapField(field_descriptor)
[all …]
Ddescriptor_test.py139 field_descriptor = message_descriptor.fields_by_name['field1']
154 field_options = field_descriptor.GetOptions()
330 field_descriptor = message_descriptor.fields_by_name["fieldname"]
356 field_descriptor.GetOptions().Extensions[
446 def CheckFieldDescriptor(self, field_descriptor): argument
448 self.assertEqual(field_descriptor.name, 'optional_int32')
449 self.assertEqual(field_descriptor.camelcase_name, 'optionalInt32')
450 self.assertEqual(field_descriptor.full_name,
452 self.assertEqual(field_descriptor.containing_type.name, 'TestAllTypes')
454 self.assertEqual(field_descriptor, field_descriptor)
[all …]
Dunknown_fields_test.py162 field_descriptor = self.descriptor.fields_by_name[name]
163 wire_type = type_checkers.FIELD_TYPE_TO_WIRE_TYPE[field_descriptor.type]
164 field_tag = encoder.TagBytes(field_descriptor.number, wire_type)
170 return result_dict[field_descriptor]
273 field_descriptor = self.descriptor.fields_by_name[name]
274 wire_type = type_checkers.FIELD_TYPE_TO_WIRE_TYPE[field_descriptor.type]
275 field_tag = encoder.TagBytes(field_descriptor.number, wire_type)
282 return result_dict[field_descriptor]
Dencoder.py343 def MapSizer(field_descriptor): argument
348 message_type = field_descriptor.message_type
349 message_sizer = MessageSizer(field_descriptor.number, False, False)
803 def MapEncoder(field_descriptor): argument
815 message_type = field_descriptor.message_type
816 encode_message = MessageEncoder(field_descriptor.number, False, False)
Ddecoder.py719 def MapDecoder(field_descriptor, new_default, is_message_map): argument
722 key = field_descriptor
723 tag_bytes = encoder.TagBytes(field_descriptor.number,
728 message_type = field_descriptor.message_type
Dtype_checkers.py61 def SupportsOpenEnums(field_descriptor): argument
62 return field_descriptor.containing_type.syntax == "proto3"
Dreflection_test.py2831 for field_descriptor, _ in proto.ListFields():
2832 self.assertEqual(False, field_descriptor.GetOptions().packed)
2837 for field_descriptor, _ in proto.ListFields():
2838 self.assertEqual(True, field_descriptor.GetOptions().packed)
2840 field_descriptor.label)
/frameworks/opt/gamesdk/third_party/protobuf-3.0.0/src/google/protobuf/compiler/cpp/
Dcpp_map_field.cc42 bool IsProto3Field(const FieldDescriptor* field_descriptor) { in IsProto3Field() argument
43 const FileDescriptor* file_descriptor = field_descriptor->file(); in IsProto3Field()
Dcpp_helpers.h111 bool IsFieldDependent(const FieldDescriptor* field_descriptor);
/frameworks/opt/gamesdk/third_party/protobuf-3.0.0/src/google/protobuf/
Ddescriptor.cc272 const FieldDescriptor* field_descriptor; member
298 CONSTRUCTOR(FieldDescriptor , FIELD , field_descriptor ) in CONSTRUCTOR()
311 case FIELD : return field_descriptor ->file(); in CONSTRUCTOR()
1220 !result.field_descriptor->is_extension()) { in FindFieldByName()
1221 return result.field_descriptor; in FindFieldByName()
1231 result.field_descriptor->is_extension()) { in FindExtensionByName()
1232 return result.field_descriptor; in FindExtensionByName()
1360 if (!result.IsNull() && !result.field_descriptor->is_extension()) { in FindFieldByName()
1361 return result.field_descriptor; in FindFieldByName()
1382 if (!result.IsNull() && result.field_descriptor->is_extension()) { in FindExtensionByName()
[all …]
Dmap_test.cc2615 const FieldDescriptor* field_descriptor = in TEST() local
2618 field_descriptor->message_type()->FindFieldByName("value"); in TEST()
2620 message.GetReflection()->AddMessage(&message, field_descriptor); in TEST()
/frameworks/opt/gamesdk/third_party/protobuf-3.0.0/src/google/protobuf/compiler/python/
Dpython_generator.cc844 const FieldDescriptor& field_descriptor = *descriptor.field(i); in FixForeignFieldsInDescriptor() local
845 FixForeignFieldsInField(&descriptor, field_descriptor, "fields_by_name"); in FixForeignFieldsInDescriptor()