Class: StrawberryAPI::Team
- Inherits:
-
Object
- Object
- StrawberryAPI::Team
- Defined in:
- lib/strawberry_api/team.rb
Instance Attribute Summary collapse
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#quota ⇒ Object
Returns the value of attribute quota.
-
#quota_mail_sent ⇒ Object
Returns the value of attribute quota_mail_sent.
-
#space_used ⇒ Object
Returns the value of attribute space_used.
-
#updated_at ⇒ Object
Returns the value of attribute updated_at.
-
#users ⇒ Object
Returns the value of attribute users.
Instance Method Summary collapse
-
#initialize(params = {}) ⇒ Team
constructor
A new instance of Team.
Constructor Details
#initialize(params = {}) ⇒ Team
Returns a new instance of Team
14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/strawberry_api/team.rb', line 14 def initialize(params = {}) params.each do |k, v| if k == 'users' v.map! do |user| User.new(user) end end instance_variable_set("@#{k}", v) unless v.nil? end end |
Instance Attribute Details
#created_at ⇒ Object
Returns the value of attribute created_at
7 8 9 |
# File 'lib/strawberry_api/team.rb', line 7 def created_at @created_at end |
#id ⇒ Object
Returns the value of attribute id
5 6 7 |
# File 'lib/strawberry_api/team.rb', line 5 def id @id end |
#name ⇒ Object
Returns the value of attribute name
6 7 8 |
# File 'lib/strawberry_api/team.rb', line 6 def name @name end |
#quota ⇒ Object
Returns the value of attribute quota
10 11 12 |
# File 'lib/strawberry_api/team.rb', line 10 def quota @quota end |
#quota_mail_sent ⇒ Object
Returns the value of attribute quota_mail_sent
9 10 11 |
# File 'lib/strawberry_api/team.rb', line 9 def quota_mail_sent @quota_mail_sent end |
#space_used ⇒ Object
Returns the value of attribute space_used
11 12 13 |
# File 'lib/strawberry_api/team.rb', line 11 def space_used @space_used end |
#updated_at ⇒ Object
Returns the value of attribute updated_at
8 9 10 |
# File 'lib/strawberry_api/team.rb', line 8 def updated_at @updated_at end |
#users ⇒ Object
Returns the value of attribute users
12 13 14 |
# File 'lib/strawberry_api/team.rb', line 12 def users @users end |