Class: GrpcKit::Interceptors::Server::RequestResponse
- Inherits:
-
Object
- Object
- GrpcKit::Interceptors::Server::RequestResponse
- Defined in:
- lib/grpc_kit/interceptors/server_request_response.rb
Instance Method Summary collapse
-
#initialize(interceptors) ⇒ RequestResponse
constructor
A new instance of RequestResponse.
- #intercept(request, call, &block) ⇒ Object
Constructor Details
#initialize(interceptors) ⇒ RequestResponse
Returns a new instance of RequestResponse.
10 11 12 |
# File 'lib/grpc_kit/interceptors/server_request_response.rb', line 10 def initialize(interceptors) @registry = GrpcKit::InterceptorRegistry.new(interceptors) end |
Instance Method Details
#intercept(request, call, &block) ⇒ Object
17 18 19 |
# File 'lib/grpc_kit/interceptors/server_request_response.rb', line 17 def intercept(request, call, &block) do_intercept(@registry.build, request, call, &block) end |