Sha256: b794864926ed97e2f875fb2315893cc3282444fb288723ec064ae4c826ed3618

Contents?: true

Size: 622 Bytes

Versions: 14

Compression:

Stored size: 622 Bytes

Contents

# frozen_string_literal: true

require 'grpc_kit/interceptors'

module GrpcKit
  module Interceptors::Server
    class ServerStreamer < Streaming
      # @param interceptor [GrpcKit::Grpc::ServerInterceptor]
      # @param call [GrpcKit::Calls::Client::ServerStreamer]
      def invoke(interceptor, call)
        # We don't need a `:request` parameter but,
        # it shuoldn't remove from paramters due to having a compatibility of grpc gem.
        interceptor.server_streamer(request: nil, call: call, method: call.method) do |new_call = nil|
          yield(new_call || call)
        end
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
grpc_kit-0.5.1 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.5.0 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.4.0 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.9 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.8 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.7 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.6 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.5 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.4 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.3 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.2 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.1 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.3.0 lib/grpc_kit/interceptors/server_server_streamer.rb
grpc_kit-0.2.1 lib/grpc_kit/interceptors/server_server_streamer.rb