Class: PiwikAnalytics::Configuration
- Inherits:
-
Object
- Object
- PiwikAnalytics::Configuration
- Defined in:
- lib/piwik_analytics/configuration.rb
Instance Method Summary collapse
-
#disabled? ⇒ Boolean
Whether or not to disable Piwik.
-
#id_site ⇒ Object
The ID of the tracked website Defaults to 1.
-
#protocol ⇒ Object
The protocol for requests to the Piwik Defaults to nil.
-
#url ⇒ Object
The url of the Piwik instance Defaults to localhost.
-
#use_async? ⇒ Boolean
Whether or not to use the async tracking Defaults to false.
Instance Method Details
#disabled? ⇒ Boolean
Whether or not to disable Piwik. Defaults to false.
40 41 42 |
# File 'lib/piwik_analytics/configuration.rb', line 40 def disabled? @disabled ||= (user_configuration_from_key('disabled') || false) end |
#id_site ⇒ Object
The ID of the tracked website Defaults to 1
24 25 26 |
# File 'lib/piwik_analytics/configuration.rb', line 24 def id_site @id_site ||= (user_configuration_from_key('id_site') || 1) end |
#protocol ⇒ Object
The protocol for requests to the Piwik Defaults to nil
16 17 18 |
# File 'lib/piwik_analytics/configuration.rb', line 16 def protocol @protocol ||= user_configuration_from_key('protocol') end |
#url ⇒ Object
The url of the Piwik instance Defaults to localhost
8 9 10 |
# File 'lib/piwik_analytics/configuration.rb', line 8 def url @url ||= (user_configuration_from_key('url') || 'localhost') end |
#use_async? ⇒ Boolean
Whether or not to use the async tracking Defaults to false
32 33 34 |
# File 'lib/piwik_analytics/configuration.rb', line 32 def use_async? @use_async ||= (user_configuration_from_key('use_async') || false) end |