Class: Slack::RealTime::Concurrency::Eventmachine::Client

Inherits:
Faye::WebSocket::Client
  • Object
show all
Defined in:
lib/slack/real_time/concurrency/eventmachine.rb

Instance Method Summary collapse

Constructor Details

#initialize(url, protocols = nil, options = {}) ⇒ Client

Returns a new instance of Client.



10
11
12
13
14
# File 'lib/slack/real_time/concurrency/eventmachine.rb', line 10

def initialize(url, protocols = nil, options = {})
  options = options.dup
  @logger = options.delete(:logger) || Slack::RealTime::Config.logger || Slack::Config.logger
  super url, protocols, options
end

Instance Method Details

#parse(data) ⇒ Object



16
17
18
19
# File 'lib/slack/real_time/concurrency/eventmachine.rb', line 16

def parse(data)
  logger.debug("#{self.class}##{__method__}") { data }
  super data
end

#write(data) ⇒ Object



21
22
23
24
# File 'lib/slack/real_time/concurrency/eventmachine.rb', line 21

def write(data)
  logger.debug("#{self.class}##{__method__}") { data }
  super data
end