Sha256: aab1799da6328808e24a8e979c9eb4e842203c3433f6f3a40e0d0717fc64272c

Contents?: true

Size: 473 Bytes

Versions: 7

Compression:

Stored size: 473 Bytes

Contents

module Envoy
  module Server
    
    class Channel
      
      attr_accessor :trunk, :web
      
      def initialize trunk, web, header
        @trunk = trunk
        @web = web
        @trunk.channels[id] = self
        @trunk.send_object :connection, id
        stream header
      end
      
      def stream data
        @trunk.send_object :stream, id, data
      end
      
      def id
        @id ||= SecureRandom.hex(4)
      end
      
    end
    
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
envoy-proxy-0.0.8 lib/envoy/server/channel.rb
envoy-proxy-0.0.7 lib/envoy/server/channel.rb
envoy-proxy-0.0.6 lib/envoy/server/channel.rb
envoy-proxy-0.0.5 lib/envoy/server/channel.rb
envoy-proxy-0.0.4 lib/envoy/server/channel.rb
envoy-proxy-0.0.2 lib/envoy/server/channel.rb
envoy-proxy-0.0.1 lib/envoy/server/channel.rb