Class: Basecamp::Types::MyAssignmentParent
- Inherits:
-
Object
- Object
- Basecamp::Types::MyAssignmentParent
- Includes:
- TypeHelpers
- Defined in:
- lib/basecamp/generated/types.rb
Overview
MyAssignmentParent
Instance Attribute Summary collapse
-
#app_url ⇒ Object
Returns the value of attribute app_url.
-
#id ⇒ Object
Returns the value of attribute id.
-
#title ⇒ Object
Returns the value of attribute title.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ MyAssignmentParent
constructor
A new instance of MyAssignmentParent.
- #to_h ⇒ Object
- #to_json(*args) ⇒ Object
Constructor Details
#initialize(data = {}) ⇒ MyAssignmentParent
Returns a new instance of MyAssignmentParent.
2099 2100 2101 2102 2103 |
# File 'lib/basecamp/generated/types.rb', line 2099 def initialize(data = {}) @id = parse_integer(data["id"]) @app_url = data["app_url"] @title = data["title"] end |
Instance Attribute Details
#app_url ⇒ Object
Returns the value of attribute app_url.
2092 2093 2094 |
# File 'lib/basecamp/generated/types.rb', line 2092 def app_url @app_url end |
#id ⇒ Object
Returns the value of attribute id.
2092 2093 2094 |
# File 'lib/basecamp/generated/types.rb', line 2092 def id @id end |
#title ⇒ Object
Returns the value of attribute title.
2092 2093 2094 |
# File 'lib/basecamp/generated/types.rb', line 2092 def title @title end |
Class Method Details
.required_fields ⇒ Array<Symbol>
2095 2096 2097 |
# File 'lib/basecamp/generated/types.rb', line 2095 def self.required_fields %i[id].freeze end |
Instance Method Details
#to_h ⇒ Object
2105 2106 2107 2108 2109 2110 2111 |
# File 'lib/basecamp/generated/types.rb', line 2105 def to_h { "id" => @id, "app_url" => @app_url, "title" => @title, }.compact end |
#to_json(*args) ⇒ Object
2113 2114 2115 |
# File 'lib/basecamp/generated/types.rb', line 2113 def to_json(*args) to_h.to_json(*args) end |