class FanartTv::Configuration
Constants
- DEFAULT_CACHE_PATH
- DEFAULT_PERFORM_CACHING
- DEFAULT_QUERY_INTERVAL
- DEFAULT_TRIES_LIMIT
- DEFAULT_WEBSERVICE_URL_ARTIST
Attributes
api_key[RW]
app_name[RW]
app_version[RW]
cache_path[RW]
contact[RW]
perform_caching[RW]
query_interval[RW]
tries_limit[RW]
webservice_url_artist[RW]
Public Class Methods
new()
click to toggle source
# File lib/fanart_tv/configuration.rb, line 14 def initialize @webservice_url_artist = DEFAULT_WEBSERVICE_URL_ARTIST @query_interval = DEFAULT_QUERY_INTERVAL @tries_limit = DEFAULT_TRIES_LIMIT @cache_path = DEFAULT_CACHE_PATH @perform_caching = DEFAULT_PERFORM_CACHING end
Public Instance Methods
user_agent_string()
click to toggle source
# File lib/fanart_tv/configuration.rb, line 27 def user_agent_string %w[ app_name app_version contact ].each do |param| raise "#{param} must be set" if instance_variable_get("@#{param}").nil? end "#{@app_name}/#{@app_version} ( #{@contact} )" end