Class: Basecamp::Types::EverythingBoost
- Inherits:
-
Object
- Object
- Basecamp::Types::EverythingBoost
- Includes:
- TypeHelpers
- Defined in:
- lib/basecamp/generated/types.rb
Overview
EverythingBoost
Instance Attribute Summary collapse
-
#booster ⇒ Object
Returns the value of attribute booster.
-
#content ⇒ Object
Returns the value of attribute content.
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#id ⇒ Object
Returns the value of attribute id.
-
#recording ⇒ Object
Returns the value of attribute recording.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ EverythingBoost
constructor
A new instance of EverythingBoost.
- #to_h ⇒ Object
- #to_json(*args) ⇒ Object
Constructor Details
#initialize(data = {}) ⇒ EverythingBoost
Returns a new instance of EverythingBoost.
1427 1428 1429 1430 1431 1432 1433 |
# File 'lib/basecamp/generated/types.rb', line 1427 def initialize(data = {}) @booster = parse_type(data["booster"], "Person") @content = data["content"] @created_at = parse_datetime(data["created_at"]) @id = parse_integer(data["id"]) @recording = parse_type(data["recording"], "Recording") end |
Instance Attribute Details
#booster ⇒ Object
Returns the value of attribute booster.
1420 1421 1422 |
# File 'lib/basecamp/generated/types.rb', line 1420 def booster @booster end |
#content ⇒ Object
Returns the value of attribute content.
1420 1421 1422 |
# File 'lib/basecamp/generated/types.rb', line 1420 def content @content end |
#created_at ⇒ Object
Returns the value of attribute created_at.
1420 1421 1422 |
# File 'lib/basecamp/generated/types.rb', line 1420 def created_at @created_at end |
#id ⇒ Object
Returns the value of attribute id.
1420 1421 1422 |
# File 'lib/basecamp/generated/types.rb', line 1420 def id @id end |
#recording ⇒ Object
Returns the value of attribute recording.
1420 1421 1422 |
# File 'lib/basecamp/generated/types.rb', line 1420 def recording @recording end |
Class Method Details
.required_fields ⇒ Array<Symbol>
1423 1424 1425 |
# File 'lib/basecamp/generated/types.rb', line 1423 def self.required_fields %i[booster content created_at id recording].freeze end |
Instance Method Details
#to_h ⇒ Object
1435 1436 1437 1438 1439 1440 1441 1442 1443 |
# File 'lib/basecamp/generated/types.rb', line 1435 def to_h { "booster" => @booster, "content" => @content, "created_at" => @created_at, "id" => @id, "recording" => @recording, }.compact end |
#to_json(*args) ⇒ Object
1445 1446 1447 |
# File 'lib/basecamp/generated/types.rb', line 1445 def to_json(*args) to_h.to_json(*args) end |