Home
last modified time | relevance | path

Searched refs:type_url (Results 1 – 25 of 38) sorted by relevance

12

/external/protobuf/src/google/protobuf/util/
Djson_util.h70 const string& type_url,
76 TypeResolver* resolver, const string& type_url, in BinaryToJsonStream() argument
79 return BinaryToJsonStream(resolver, type_url, binary_input, json_output, in BinaryToJsonStream()
85 const string& type_url,
91 const string& type_url, in BinaryToJsonString() argument
94 return BinaryToJsonString(resolver, type_url, binary_input, json_output, in BinaryToJsonString()
106 const string& type_url,
112 const string& type_url,
Djson_util.cc74 const string& type_url, in BinaryToJsonStream() argument
80 RETURN_IF_ERROR(resolver->ResolveMessageType(type_url, &type)); in BinaryToJsonStream()
95 const string& type_url, in BinaryToJsonString() argument
101 return BinaryToJsonStream(resolver, type_url, &input_stream, &output_stream, in BinaryToJsonString()
142 const string& type_url, in JsonToBinaryStream() argument
146 RETURN_IF_ERROR(resolver->ResolveMessageType(type_url, &type)); in JsonToBinaryStream()
166 const string& type_url, in JsonToBinaryString() argument
171 return JsonToBinaryStream(resolver, type_url, &input_stream, &output_stream); in JsonToBinaryString()
Dtype_resolver_util.cc57 bool SplitTypeUrl(const string& type_url, string* url_prefix, in SplitTypeUrl() argument
59 size_t pos = type_url.find_last_of("/"); in SplitTypeUrl()
63 *url_prefix = type_url.substr(0, pos); in SplitTypeUrl()
64 *message_name = type_url.substr(pos + 1); in SplitTypeUrl()
74 Status ResolveMessageType(const string& type_url, Type* type) { in ResolveMessageType() argument
76 if (!SplitTypeUrl(type_url, &url_prefix, &message_name) || in ResolveMessageType()
80 url_prefix_, "/<typename>', got: ", type_url)); in ResolveMessageType()
95 Status ResolveEnumType(const string& type_url, Enum* enum_type) { in ResolveEnumType() argument
97 if (!SplitTypeUrl(type_url, &url_prefix, &type_name) || in ResolveEnumType()
101 url_prefix_, "/<typename>', got: ", type_url)); in ResolveEnumType()
Dtype_resolver.h61 const string& type_url, google::protobuf::Type* message_type) = 0;
64 virtual util::Status ResolveEnumType(const string& type_url,
Dtype_resolver_util_test.cc95 const string& type_url) { in CheckFieldTypeUrl() argument
100 return field->type_url() == type_url; in CheckFieldTypeUrl()
/external/protobuf/src/google/protobuf/
Dany.cc53 AnyMetadata::AnyMetadata(UrlType* type_url, ValueType* value) in AnyMetadata() argument
54 : type_url_(type_url), value_(value) { in AnyMetadata()
78 const string type_url = type_url_->GetNoArena( in InternalIs() local
81 if (!ParseAnyTypeUrl(type_url, &full_name)) { in InternalIs()
87 bool ParseAnyTypeUrl(const string& type_url, string* full_type_name) { in ParseAnyTypeUrl() argument
88 size_t pos = type_url.find_last_of("/"); in ParseAnyTypeUrl()
89 if (pos == string::npos || pos + 1 == type_url.size()) { in ParseAnyTypeUrl()
92 *full_type_name = type_url.substr(pos + 1); in ParseAnyTypeUrl()
Dany.pb.cc220 this->type_url().data(), this->type_url().length(), in MergePartialFromCodedStream()
268 if (this->type_url().size() > 0) { in SerializeWithCachedSizes()
270 this->type_url().data(), this->type_url().length(), in SerializeWithCachedSizes()
274 1, this->type_url(), output); in SerializeWithCachedSizes()
290 if (this->type_url().size() > 0) { in SerializeWithCachedSizesToArray()
292 this->type_url().data(), this->type_url().length(), in SerializeWithCachedSizesToArray()
297 1, this->type_url(), target); in SerializeWithCachedSizesToArray()
316 if (this->type_url().size() > 0) { in ByteSize()
319 this->type_url()); in ByteSize()
353 if (from.type_url().size() > 0) { in MergeFrom()
[all …]
Dany.pb.h114 const ::std::string& type_url() const;
120 void set_allocated_type_url(::std::string* type_url);
161 inline const ::std::string& Any::type_url() const { in type_url() function
191 inline void Any::set_allocated_type_url(::std::string* type_url) { in set_allocated_type_url() argument
192 if (type_url != NULL) { in set_allocated_type_url()
197 …e_url_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), type_url); in set_allocated_type_url()
Dany.h51 AnyMetadata(UrlType* type_url, ValueType* value);
95 bool ParseAnyTypeUrl(const string& type_url, string* full_type_name);
Dtype.pb.cc1229 this->type_url().data(), this->type_url().length(), in MergePartialFromCodedStream()
1372 if (this->type_url().size() > 0) { in SerializeWithCachedSizes()
1374 this->type_url().data(), this->type_url().length(), in SerializeWithCachedSizes()
1378 6, this->type_url(), output); in SerializeWithCachedSizes()
1452 if (this->type_url().size() > 0) { in SerializeWithCachedSizesToArray()
1454 this->type_url().data(), this->type_url().length(), in SerializeWithCachedSizesToArray()
1459 6, this->type_url(), target); in SerializeWithCachedSizesToArray()
1536 if (this->type_url().size() > 0) { in ByteSize()
1539 this->type_url()); in ByteSize()
1614 if (from.type_url().size() > 0) { in MergeFrom()
[all …]
/external/protobuf/src/google/protobuf/util/internal/
Dtype_info.cc62 StringPiece type_url) const { in ResolveTypeUrl()
63 map<StringPiece, StatusOrType>::iterator it = cached_types_.find(type_url); in ResolveTypeUrl()
70 *string_storage_.insert(type_url.ToString()).first; in ResolveTypeUrl()
81 StringPiece type_url) const { in GetTypeByTypeUrl()
82 StatusOrType result = ResolveTypeUrl(type_url); in GetTypeByTypeUrl()
87 StringPiece type_url) const { in GetEnumByTypeUrl()
88 map<StringPiece, StatusOrEnum>::iterator it = cached_enums_.find(type_url); in GetEnumByTypeUrl()
95 *string_storage_.insert(type_url.ToString()).first; in GetEnumByTypeUrl()
Dtype_info_test_helper.cc92 io::CodedInputStream* coded_input, const string& type_url) { in NewProtoSource() argument
93 const google::protobuf::Type* type = typeinfo_->GetTypeByTypeUrl(type_url); in NewProtoSource()
105 const string& type_url, strings::ByteSink* output, ErrorListener* listener, in NewProtoWriter() argument
107 const google::protobuf::Type* type = typeinfo_->GetTypeByTypeUrl(type_url); in NewProtoWriter()
119 const string& type_url, ObjectWriter* writer) { in NewDefaultValueWriter() argument
120 const google::protobuf::Type* type = typeinfo_->GetTypeByTypeUrl(type_url); in NewDefaultValueWriter()
Dtype_info.h58 StringPiece type_url) const = 0;
65 StringPiece type_url) const = 0;
72 StringPiece type_url) const = 0;
Dtype_info_test_helper.h78 const string& type_url);
81 const string& type_url, strings::ByteSink* output,
84 DefaultValueObjectWriter* NewDefaultValueWriter(const string& type_url,
Dprotostream_objectwriter.cc1007 const TypeRenderer* type_renderer = FindTypeRenderer(field->type_url()); in RenderDataPiece()
1016 InvalidValue(field->type_url(), in RenderDataPiece()
1026 field->type_url() != kStructNullValueTypeUrl) { in RenderDataPiece()
1041 const TypeRenderer* type_renderer = FindTypeRenderer(field->type_url()); in RenderDataPiece()
1046 InvalidValue(field->type_url(), in RenderDataPiece()
1056 field->type_url() != kStructNullValueTypeUrl) { in RenderDataPiece()
1125 ProtoStreamObjectWriter::FindTypeRenderer(const string& type_url) { in FindTypeRenderer() argument
1127 return FindOrNull(*renderers_, type_url); in FindTypeRenderer()
1170 if (field.type_url().empty() || in IsMap()
1177 typeinfo()->GetTypeByTypeUrl(field.type_url()); in IsMap()
[all …]
Dprotostream_objectsource.cc256 typeinfo_->GetTypeByTypeUrl(field->type_url()); in RenderMap()
570 string type_url; in RenderAny() local
586 os->stream_->ReadString(&type_url, type_url_size); in RenderAny()
599 if (!type_url.empty()) { in RenderAny()
600 ow->RenderString("@type", type_url); in RenderAny()
607 if (type_url.empty()) { in RenderAny()
614 os->typeinfo_->ResolveTypeUrl(type_url); in RenderAny()
633 ow->RenderString("@type", type_url); in RenderAny()
719 ProtoStreamObjectSource::FindTypeRenderer(const string& type_url) { in FindTypeRenderer() argument
721 return FindOrNull(*renderers_, type_url); in FindTypeRenderer()
[all …]
Ddefault_value_objectwriter.cc270 typeinfo->ResolveTypeUrl(sub_field.type_url()); in GetMapValueType()
272 GOOGLE_LOG(WARNING) << "Cannot resolve type '" << sub_field.type_url() << "'."; in GetMapValueType()
334 typeinfo->ResolveTypeUrl(field.type_url()); in PopulateChildren()
337 GOOGLE_LOG(WARNING) << "Cannot resolve type '" << field.type_url() << "'."; in PopulateChildren()
398 typeinfo->GetEnumByTypeUrl(field.type_url()); in FindEnumDefault()
400 GOOGLE_LOG(WARNING) << "Could not find enum with type '" << field.type_url() in FindEnumDefault()
Dproto_writer.cc446 StrCat("Missing descriptor for field: ", field->type_url())); in StartObject()
485 StrCat("Missing descriptor for field: ", field->type_url())); in StartList()
514 StrCat("Missing descriptor for field: ", field->type_url())); in RenderDataPiece()
568 InvalidValue(field.type_url().empty() in RenderPrimitiveField()
570 : field.type_url(), in RenderPrimitiveField()
639 typeinfo_->GetEnumByTypeUrl(field.type_url()), in RenderPrimitiveField()
703 ? typeinfo_->GetTypeByTypeUrl(field->type_url()) in LookupType()
Dutility.cc130 const StringPiece GetTypeWithoutUrl(StringPiece type_url) { in GetTypeWithoutUrl() argument
131 size_t idx = type_url.rfind('/'); in GetTypeWithoutUrl()
132 return type_url.substr(idx + 1); in GetTypeWithoutUrl()
/external/tensorflow/tensorflow/core/platform/
Dprotobuf_internal.h46 if (any.type_url() != strings::StrCat("type.googleapis.com/", type_name)) { in ParseAny()
49 ". Got: ", string(any.type_url().data(), any.type_url().size()), "."); in ParseAny()
60 ". Got: ", string(any.type_url().data(), any.type_url().size()), "."); in ParseAny()
/external/protobuf/python/google/protobuf/
Djson_format.py212 type_url = message.type_url
213 js['@type'] = type_url
214 sub_message = _CreateMessageFromTypeUrl(type_url)
227 def _CreateMessageFromTypeUrl(type_url): argument
231 type_name = type_url.split('/')[-1]
236 'Can not find message descriptor by type_url: {0}.'.format(type_url))
430 type_url = value['@type']
434 sub_message = _CreateMessageFromTypeUrl(type_url)
446 message.type_url = type_url
/external/protobuf/conformance/
Dconformance_cpp.cc61 string* type_url; variable
103 Status status = JsonToBinaryString(type_resolver, *type_url, in DoTest()
137 Status status = BinaryToJsonString(type_resolver, *type_url, proto_binary, in DoTest()
199 type_url = new string(GetTypeUrl(TestAllTypes::descriptor())); in main()
/external/golang-protobuf/proto/
Dany_test.go250 type_url: "foo"
263 type_url: "ttt/proto3_proto.Nested"
/external/protobuf/python/google/protobuf/internal/
Dwell_known_types_test.py591 self.assertEqual(msg.value.type_url,
627 self.assertEqual(msg.type_url,
631 self.assertEqual(msg.type_url,
635 self.assertEqual(msg.type_url,
Dwell_known_types.py72 self.type_url = '%s/%s' % (type_url_prefix, msg.DESCRIPTOR.full_name)
74 self.type_url = '%s%s' % (type_url_prefix, msg.DESCRIPTOR.full_name)
88 return self.type_url.split('/')[-1]

12