summaryrefslogtreecommitdiffstats
path: root/contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h
diff options
context:
space:
mode:
authordvshkurko <[email protected]>2022-02-10 16:45:51 +0300
committerDaniil Cherednik <[email protected]>2022-02-10 16:45:51 +0300
commit321ee9bce31ec6e238be26dbcbe539cffa2c3309 (patch)
tree14407a2757cbf29eb97e266b7f07e851f971000c /contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h
parent2f6ca198245aeffd5e2d82b65927c2465b68b4f5 (diff)
Restoring authorship annotation for <[email protected]>. Commit 1 of 2.
Diffstat (limited to 'contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h')
-rw-r--r--contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h22
1 files changed, 11 insertions, 11 deletions
diff --git a/contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h b/contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h
index 2e102135a36..b1ac4274531 100644
--- a/contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h
+++ b/contrib/libs/grpc/include/grpcpp/impl/codegen/proto_utils.h
@@ -42,7 +42,7 @@ extern CoreCodegenInterface* g_core_codegen_interface;
// ProtoBufferWriter must be a subclass of ::protobuf::io::ZeroCopyOutputStream.
template <class ProtoBufferWriter, class T>
-Status GenericSerialize(const grpc::protobuf::MessageLite& msg, ByteBuffer* bb,
+Status GenericSerialize(const grpc::protobuf::MessageLite& msg, ByteBuffer* bb,
bool* own_buffer) {
static_assert(std::is_base_of<protobuf::io::ZeroCopyOutputStream,
ProtoBufferWriter>::value,
@@ -68,8 +68,8 @@ Status GenericSerialize(const grpc::protobuf::MessageLite& msg, ByteBuffer* bb,
// BufferReader must be a subclass of ::protobuf::io::ZeroCopyInputStream.
template <class ProtoBufferReader, class T>
-Status GenericDeserialize(ByteBuffer* buffer,
- grpc::protobuf::MessageLite* msg) {
+Status GenericDeserialize(ByteBuffer* buffer,
+ grpc::protobuf::MessageLite* msg) {
static_assert(std::is_base_of<protobuf::io::ZeroCopyInputStream,
ProtoBufferReader>::value,
"ProtoBufferReader must be a subclass of "
@@ -83,7 +83,7 @@ Status GenericDeserialize(ByteBuffer* buffer,
if (!reader.status().ok()) {
return reader.status();
}
- if (!msg->ParseFromZeroCopyStream(&reader)) {
+ if (!msg->ParseFromZeroCopyStream(&reader)) {
result = Status(StatusCode::INTERNAL, msg->InitializationErrorString());
}
}
@@ -98,17 +98,17 @@ Status GenericDeserialize(ByteBuffer* buffer,
// objects and grpc_byte_buffers. More information about SerializationTraits can
// be found in include/grpcpp/impl/codegen/serialization_traits.h.
template <class T>
-class SerializationTraits<
- T, typename std::enable_if<
- std::is_base_of<grpc::protobuf::MessageLite, T>::value>::type> {
+class SerializationTraits<
+ T, typename std::enable_if<
+ std::is_base_of<grpc::protobuf::MessageLite, T>::value>::type> {
public:
- static Status Serialize(const grpc::protobuf::MessageLite& msg,
- ByteBuffer* bb, bool* own_buffer) {
+ static Status Serialize(const grpc::protobuf::MessageLite& msg,
+ ByteBuffer* bb, bool* own_buffer) {
return GenericSerialize<ProtoBufferWriter, T>(msg, bb, own_buffer);
}
- static Status Deserialize(ByteBuffer* buffer,
- grpc::protobuf::MessageLite* msg) {
+ static Status Deserialize(ByteBuffer* buffer,
+ grpc::protobuf::MessageLite* msg) {
return GenericDeserialize<ProtoBufferReader, T>(buffer, msg);
}
};