Class: HTTPX::Plugins::Proxy::Socks4::SocksParser

Inherits:
Object
  • Object
show all
Includes:
Callbacks
Defined in:
lib/httpx/plugins/proxy/socks4.rb

Instance Method Summary collapse

Methods included from Callbacks

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

Constructor Details

#initialize(buffer, options) ⇒ SocksParser

Returns a new instance of SocksParser.



90
91
92
93
# File 'lib/httpx/plugins/proxy/socks4.rb', line 90

def initialize(buffer, options)
  @buffer = buffer
  @options = Options.new(options)
end

Instance Method Details

#<<(packet) ⇒ Object



103
104
105
# File 'lib/httpx/plugins/proxy/socks4.rb', line 103

def <<(packet)
  emit(:packet, packet)
end

#closeObject



95
# File 'lib/httpx/plugins/proxy/socks4.rb', line 95

def close; end

#consumeObject



97
# File 'lib/httpx/plugins/proxy/socks4.rb', line 97

def consume(*); end

#empty?Boolean

Returns:

  • (Boolean)


99
100
101
# File 'lib/httpx/plugins/proxy/socks4.rb', line 99

def empty?
  true
end