Class: Proxy

Inherits:
Twing::Modules::Base
  • Object
show all
Defined in:
lib/twing_proxy/proxy.rb

Instance Method Summary collapse

Constructor Details

#initialize(*args) ⇒ Proxy

Returns a new instance of Proxy.



5
6
7
8
# File 'lib/twing_proxy/proxy.rb', line 5

def initialize(*args)
  super
  @endpoints = setting.endpoints
end

Instance Method Details

#on_message(object) ⇒ Object



10
11
12
13
14
15
16
# File 'lib/twing_proxy/proxy.rb', line 10

def on_message(object)
  case object
  when Twitter::Tweet
    logger.debug("Tweet #{object.id}")
    execute(object)
  end
end