diff options
Diffstat (limited to 'include/grpc++/server_context.h')
-rw-r--r-- | include/grpc++/server_context.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/grpc++/server_context.h b/include/grpc++/server_context.h index 6f094eda3d..3bfa48fbb6 100644 --- a/include/grpc++/server_context.h +++ b/include/grpc++/server_context.h @@ -37,6 +37,7 @@ #include <map> #include <memory> +#include <grpc/compression.h> #include <grpc/support/time.h> #include <grpc++/auth_context.h> #include <grpc++/config.h> @@ -103,6 +104,16 @@ class ServerContext { return client_metadata_; } + grpc_compression_level get_compression_level() const { + return compression_level_; + } + void set_compression_level(grpc_compression_level level); + + grpc_compression_algorithm get_compression_algorithm() const { + return compression_algorithm_; + } + void set_compression_algorithm(grpc_compression_algorithm algorithm); + std::shared_ptr<const AuthContext> auth_context() const; private: @@ -154,6 +165,9 @@ class ServerContext { std::multimap<grpc::string, grpc::string> client_metadata_; std::multimap<grpc::string, grpc::string> initial_metadata_; std::multimap<grpc::string, grpc::string> trailing_metadata_; + + grpc_compression_level compression_level_; + grpc_compression_algorithm compression_algorithm_; }; } // namespace grpc |