Class: Sendly::Account
- Inherits:
-
Object
- Object
- Sendly::Account
- Defined in:
- lib/sendly/types.rb
Overview
Represents account information
Instance Attribute Summary collapse
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#email ⇒ Object
readonly
Returns the value of attribute email.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(data) ⇒ Account
constructor
A new instance of Account.
Constructor Details
#initialize(data) ⇒ Account
Returns a new instance of Account.
401 402 403 404 405 406 |
# File 'lib/sendly/types.rb', line 401 def initialize(data) @id = data["id"] @email = data["email"] @name = data["name"] @created_at = parse_time(data["created_at"] || data["createdAt"]) end |
Instance Attribute Details
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
399 400 401 |
# File 'lib/sendly/types.rb', line 399 def created_at @created_at end |
#email ⇒ Object (readonly)
Returns the value of attribute email.
399 400 401 |
# File 'lib/sendly/types.rb', line 399 def email @email end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
399 400 401 |
# File 'lib/sendly/types.rb', line 399 def id @id end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
399 400 401 |
# File 'lib/sendly/types.rb', line 399 def name @name end |