diff options
author | Yash Tibrewal <yashkt@google.com> | 2018-11-15 13:55:56 -0800 |
---|---|---|
committer | Yash Tibrewal <yashkt@google.com> | 2018-11-15 13:55:56 -0800 |
commit | 0911e489e3fe22e2ca5d7c927dac83358f2f05b7 (patch) | |
tree | f20fe0049cb0303e370e7a751416a8b2ea02521f /include/grpcpp/impl/codegen/interceptor_common.h | |
parent | ceeb28a360d48389edb8c1c91a1efac46e24a9b7 (diff) |
Add a method to check whether the message was received successfully
Diffstat (limited to 'include/grpcpp/impl/codegen/interceptor_common.h')
-rw-r--r-- | include/grpcpp/impl/codegen/interceptor_common.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/grpcpp/impl/codegen/interceptor_common.h b/include/grpcpp/impl/codegen/interceptor_common.h index d23b71f8a7..b2e92dd6f3 100644 --- a/include/grpcpp/impl/codegen/interceptor_common.h +++ b/include/grpcpp/impl/codegen/interceptor_common.h @@ -103,6 +103,8 @@ class InterceptorBatchMethodsImpl void* GetRecvMessage() override { return recv_message_; } + bool GetRecvMessageStatus() override { return *got_message_; } + std::multimap<grpc::string_ref, grpc::string_ref>* GetRecvInitialMetadata() override { return recv_initial_metadata_->map(); @@ -432,6 +434,14 @@ class CancelInterceptorBatchMethods return nullptr; } + bool GetRecvMessageStatus() override { + GPR_CODEGEN_ASSERT( + false && + "It is illegal to call GetRecvMessageStatus on a method which " + "has a Cancel notification"); + return false; + } + std::multimap<grpc::string_ref, grpc::string_ref>* GetRecvInitialMetadata() override { GPR_CODEGEN_ASSERT(false && |