Class: HTTPX::Plugins::Proxy::Socks5::SocksParser

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

Instance Method Summary collapse

Methods included from Callbacks

#emit, #on, #once

Constructor Details

#initialize(buffer, options) ⇒ SocksParser

Returns a new instance of SocksParser.



119
120
121
122
# File 'lib/httpx/plugins/proxy/socks5.rb', line 119

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

Instance Method Details

#<<(packet) ⇒ Object



132
133
134
# File 'lib/httpx/plugins/proxy/socks5.rb', line 132

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

#closeObject



124
# File 'lib/httpx/plugins/proxy/socks5.rb', line 124

def close; end

#consumeObject



126
# File 'lib/httpx/plugins/proxy/socks5.rb', line 126

def consume(*); end

#empty?Boolean

Returns:

  • (Boolean)


128
129
130
# File 'lib/httpx/plugins/proxy/socks5.rb', line 128

def empty?
  true
end