class Async::HTTP::Protocol::HTTP2::Promise
def build_request(headers)
def build_request(headers) = ::Protocol::HTTP::Request.new .headers = ::Protocol::HTTP::Headers.new .each do |key, value| == SCHEME n @stream.send_failure(400, "Request scheme already specified") if request.scheme st.scheme = value key == AUTHORITY n @stream.send_failure(400, "Request authority already specified") if request.authority st.authority = value key == METHOD n @stream.send_failure(400, "Request method already specified") if request.method st.method = value key == PATH n @stream.send_failure(400, "Request path already specified") if request.path st.path = value st.headers[key] = value request
def initialize(protocol, headers, stream_id)
def initialize(protocol, headers, stream_id) super(protocol, stream_id) @request = build_request(headers) end