Class: GrpcKit::Interceptors::Client::RequestResponse

Inherits:
Object
  • Object
show all
Defined in:
lib/grpc_kit/interceptors/client_request_response.rb

Instance Method Summary collapse

Constructor Details

#initialize(interceptors) ⇒ RequestResponse

Returns a new instance of RequestResponse.

Parameters:



9
10
11
# File 'lib/grpc_kit/interceptors/client_request_response.rb', line 9

def initialize(interceptors)
  @registry = GrpcKit::InterceptorRegistry.new(interceptors)
end

Instance Method Details

#intercept(request, call, metadata, &block) ⇒ Object

Parameters:

Yield Returns:

  • (Object)

    Response object server sent



16
17
18
# File 'lib/grpc_kit/interceptors/client_request_response.rb', line 16

def intercept(request, call, , &block)
  do_intercept(@registry.build, request, call, , &block)
end