Class: TwitterImages::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/twitter_images/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



6
7
8
# File 'lib/twitter_images/configuration.rb', line 6

def initialize
  @requester = Requester.new
end

Instance Attribute Details

#amountObject

Returns the value of attribute amount.



4
5
6
# File 'lib/twitter_images/configuration.rb', line 4

def amount
  @amount
end

#directoryObject

Returns the value of attribute directory.



4
5
6
# File 'lib/twitter_images/configuration.rb', line 4

def directory
  @directory
end

#optionsObject (readonly)

Returns the value of attribute options.



3
4
5
# File 'lib/twitter_images/configuration.rb', line 3

def options
  @options
end

#requesterObject (readonly)

Returns the value of attribute requester.



3
4
5
# File 'lib/twitter_images/configuration.rb', line 3

def requester
  @requester
end

#searchObject

Returns the value of attribute search.



4
5
6
# File 'lib/twitter_images/configuration.rb', line 4

def search
  @search
end

Instance Method Details

#prepare(options) ⇒ Object



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

def prepare(options)
  check_auth
  set_directory(options[:path])
  get_search(options[:term])
  get_amount(options[:amount])
  start
end