module Ethon::Easy::Callbacks

def header_write_callback

Returns:
  • (Proc) - The callback.

Other tags:
    Example: Return the callback. -
def header_write_callback
  @header_write_callback ||= proc {|stream, size, num, object|
    result = headers
    @response_headers << stream.read_string(size * num)
    result != :abort ? size * num : -1
  }
end