Module: EventMachine::Connectify

### Home Classes Methods

### In Files

- lib/em-socksify/connect.rb
- lib/em-socksify/connectify.rb
- lib/em-socksify/errors.rb

### Namespace

- MODULE EventMachine::Connectify::CONNECT
- CLASS EventMachine::Connectify::CONNECTError

### Methods

- #connect_hook
- #connect_receive_data
- #connect_unhook
- #connectify

### Class/Module Index

Quicksearch

- EventMachine
- EventMachine::Connectify
- EventMachine::Connectify::CONNECT
- EventMachine::Connectify::CONNECTError
- EventMachine::Socksify
- EventMachine::Socksify::SOCKS5
- EventMachine::Socksify::SOCKSError
- Base64

No matching classes.

# EventMachine::Connectify

### Public Instance Methods

connect_hook() click to toggle source

    # File lib/em-socksify/connectify.rb, line 19
    def connect_hook
      extend CONNECT

      class << self
        alias receive_data connect_receive_data
      end
    end

connect_receive_data(data) click to toggle source

    # File lib/em-socksify/connectify.rb, line 35
    def connect_receive_data(data)
      @connect_data << data
      connect_parse_response
    end

connect_unhook() click to toggle source

    # File lib/em-socksify/connectify.rb, line 27
    def connect_unhook
      class << self
        remove_method :receive_data
      end

      @connect_deferrable.succeed
    end

connectify(host, port, username=nil, password=nil, &blk) click to toggle source

    # File lib/em-socksify/connectify.rb, line 4
    def connectify(host, port, username=nil, password=nil, &blk)
      @connect_target_host = host
      @connect_target_port = port
      @connect_username = username
      @connect_password = password
      @connect_data = ''

      connect_hook
      connect_send_handshake

      @connect_deferrable = DefaultDeferrable.new
      @connect_deferrable.callback(&blk) if blk
      @connect_deferrable
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.