module ARBookFinder::Configuration

Constants

DEFAULT_USER_TYPE
VALID_OPTION_KEYS

Public Class Methods

extended(base) click to toggle source
# File lib/ar_book_finder/configuration.rb, line 11
def self.extended(base)
  base.reset
end

Public Instance Methods

configure() { |self| ... } click to toggle source
# File lib/ar_book_finder/configuration.rb, line 15
def configure
  yield self
end
options() click to toggle source
# File lib/ar_book_finder/configuration.rb, line 19
def options
  VALID_OPTION_KEYS.inject({}) do |option, key|
    option.merge!(key => send(key))
  end
end
reset() click to toggle source
# File lib/ar_book_finder/configuration.rb, line 25
def reset
  self.user_type = DEFAULT_USER_TYPE
end