Module: FayeRails

Defined in:
lib/faye-rails.rb,
lib/faye-rails/filter.rb,
lib/faye-rails/version.rb,
lib/faye-rails/controller.rb,
lib/faye-rails/middleware.rb,
lib/faye-rails/rack_adapter.rb,
lib/faye-rails/controller/monitor.rb,
lib/faye-rails/controller/message.rb,
lib/faye-rails/controller/channel.rb,
lib/faye-rails/controller/observer_factory.rb

Defined Under Namespace

Classes: Controller, Engine, Filter, Middleware, RackAdapter

Constant Summary

ROOT =
File.expand_path(File.dirname(__FILE__))
VERSION =
"2.0.0"

Class Method Summary (collapse)

Class Method Details

+ (Object) client(where = nil)



34
35
36
37
38
39
40
# File 'lib/faye-rails.rb', line 34

def self.client(where=nil)
  if where
    servers.at(where).first.get_client
  else
    servers.first.get_client
  end
end

+ (Object) clients



30
31
32
# File 'lib/faye-rails.rb', line 30

def self.clients
  servers.map(&:get_client)
end

+ (Object) server(where = nil)



22
23
24
25
26
27
28
# File 'lib/faye-rails.rb', line 22

def self.server(where=nil)
  if where
    servers.at(where).first
  else
    servers.first
  end
end

+ (Object) servers



18
19
20
# File 'lib/faye-rails.rb', line 18

def self.servers
  @servers ||= ServerList.new
end