Sha256: f7dd0b7b6c35c15edf67803a350b2db789471b7fbcb9e468fce3cb590f67e38f

Contents?: true

Size: 277 Bytes

Versions: 4

Compression:

Stored size: 277 Bytes

Contents

require 'eventmachine'

module RSocks
  class TargetConnectionHandler < EM::Connection

    def source_io=(io)
      @source_io = io
    end

    def receive_data(data)
      @source_io.send_data(data)
    end

    def unbind
      @source_io.close_connection
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
r_socks-0.1.4 lib/r_socks/target_connection_handler.rb
r_socks-0.1.3 lib/r_socks/target_connection_handler.rb
r_socks-0.1.2 lib/r_socks/target_connection_handler.rb
r_socks-0.1.1 lib/r_socks/target_connection_handler.rb