Class: Analytics::Account
- Inherits:
-
Object
- Object
- Analytics::Account
- Defined in:
- lib/analytics/account.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #flush! ⇒ Object
-
#initialize(opts, access_token) ⇒ Account
constructor
A new instance of Account.
- #web_properties ⇒ Object
Constructor Details
#initialize(opts, access_token) ⇒ Account
Returns a new instance of Account.
5 6 7 8 9 |
# File 'lib/analytics/account.rb', line 5 def initialize(opts, access_token) @name = opts.fetch("name") @id = opts.fetch("id") @access_token = access_token end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
3 4 5 |
# File 'lib/analytics/account.rb', line 3 def id @id end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
3 4 5 |
# File 'lib/analytics/account.rb', line 3 def name @name end |
Instance Method Details
#flush! ⇒ Object
15 16 17 |
# File 'lib/analytics/account.rb', line 15 def flush! @web_properties = nil end |
#web_properties ⇒ Object
11 12 13 |
# File 'lib/analytics/account.rb', line 11 def web_properties @web_properties ||= request_web_properties end |