class Seahorse::Client::Plugins::RequestCallback::OptionHandler

def call(context)

def call(context)
  if context.params.is_a?(Hash) && context.params[:on_chunk_sent]
    on_chunk_sent = context.params.delete(:on_chunk_sent)
  end
  on_chunk_sent = context.config.on_chunk_sent if on_chunk_sent.nil?
  context[:on_chunk_sent] = on_chunk_sent if on_chunk_sent
  if context.params.is_a?(Hash) && context.params[:on_chunk_received]
    on_chunk_received = context.params.delete(:on_chunk_received)
  end
  on_chunk_received = context.config.on_chunk_received if on_chunk_received.nil?
  add_response_events(on_chunk_received, context) if on_chunk_received
  @handler.call(context)
end