Sha256: 737dfc64a3515e365b450ee0ac95670e02a2cefd1ab05b8308cbb777aa9e3811

Contents?: true

Size: 376 Bytes

Versions: 12

Compression:

Stored size: 376 Bytes

Contents

module Faye
  class WebSocket
    
    module Adapter
      def websocket?
        e = defined?(@env) ? @env : env
        WebSocket.websocket?(e)
      end
      
      def eventsource?
        e = defined?(@env) ? @env : env
        EventSource.eventsource?(e)
      end
      
      def async_connection?
        websocket? or eventsource?
      end
    end
    
  end
end

Version data entries

12 entries across 12 versions & 2 rubygems

Version Path
faye-websocket-0.4.6-java lib/faye/websocket/adapter.rb
faye-websocket-0.4.6 lib/faye/websocket/adapter.rb
faye-websocket-0.4.5-java lib/faye/websocket/adapter.rb
faye-websocket-0.4.5 lib/faye/websocket/adapter.rb
_bushido-faye-websocket-0.4.4 lib/faye/websocket/adapter.rb
faye-websocket-0.4.4-java lib/faye/websocket/adapter.rb
faye-websocket-0.4.4 lib/faye/websocket/adapter.rb
faye-websocket-0.4.3 lib/faye/websocket/adapter.rb
faye-websocket-0.4.2 lib/faye/websocket/adapter.rb
faye-websocket-0.4.1 lib/faye/websocket/adapter.rb
faye-websocket-0.4.0 lib/faye/websocket/adapter.rb
faye-websocket-0.3.0 lib/faye/websocket/adapter.rb