Class: HTTPX::Plugins::Proxy::HTTP::ConnectRequest

Inherits:
Request
  • Object
show all
Defined in:
lib/httpx/plugins/proxy/http.rb

Constant Summary

Constants inherited from Request

Request::ALLOWED_URI_SCHEMES, Request::USER_AGENT

Constants included from Loggable

Loggable::COLORS, Loggable::USE_DEBUG_LOG

Instance Attribute Summary

Attributes inherited from Request

#active_timeouts, #body, #drain_error, #headers, #options, #peer_address, #persistent, #response, #state, #uri, #verb

Instance Method Summary collapse

Methods inherited from Request

#authority, #can_buffer?, #complete!, #drain_body, #expects?, #inspect, #interests, #merge_headers, #origin, #persistent?, #ping!, #ping?, #query, #read_timeout, #request_timeout, #scheme, #set_timeout_callback, #trailers, #trailers?, #transition, #write_timeout

Methods included from Callbacks

#callbacks_for?, #emit, #on, #once

Methods included from Loggable

#log, #log_exception, #log_redact

Constructor Details

#initialize(uri, options) ⇒ ConnectRequest

Returns a new instance of ConnectRequest.



171
172
173
174
# File 'lib/httpx/plugins/proxy/http.rb', line 171

def initialize(uri, options)
  super("CONNECT", uri, options)
  @headers.delete("accept")
end

Instance Method Details

#pathObject



176
177
178
# File 'lib/httpx/plugins/proxy/http.rb', line 176

def path
  "#{@uri.hostname}:#{@uri.port}"
end