Class: TweetHose::Worker

Inherits:
Object
  • Object
show all
Defined in:
lib/tweethose/worker.rb

Overview

work.run

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(config) ⇒ Worker

Params:

config

a configuration object with ‘username’ and ‘password’ for Twitter



19
20
21
# File 'lib/tweethose/worker.rb', line 19

def initialize(config)
  @config = config
end

Instance Attribute Details

#configObject

Returns the value of attribute config.



13
14
15
# File 'lib/tweethose/worker.rb', line 13

def config
  @config
end

Instance Method Details

#runObject

Run the worker.



26
27
28
29
30
# File 'lib/tweethose/worker.rb', line 26

def run()
  tell "Running TweetHose"
  configure(@config)
  start_tracking
end