Class: Basecamp::Types::CalendarAttributes
- Inherits:
-
Object
- Object
- Basecamp::Types::CalendarAttributes
- Includes:
- TypeHelpers
- Defined in:
- lib/basecamp/generated/types.rb
Overview
CalendarAttributes
Instance Attribute Summary collapse
-
#color ⇒ Object
Returns the value of attribute color.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ CalendarAttributes
constructor
A new instance of CalendarAttributes.
- #to_h ⇒ Object
- #to_json(*args) ⇒ Object
Constructor Details
#initialize(data = {}) ⇒ CalendarAttributes
Returns a new instance of CalendarAttributes.
414 415 416 |
# File 'lib/basecamp/generated/types.rb', line 414 def initialize(data = {}) @color = data["color"] end |
Instance Attribute Details
#color ⇒ Object
Returns the value of attribute color.
407 408 409 |
# File 'lib/basecamp/generated/types.rb', line 407 def color @color end |
Class Method Details
.required_fields ⇒ Array<Symbol>
410 411 412 |
# File 'lib/basecamp/generated/types.rb', line 410 def self.required_fields %i[color].freeze end |
Instance Method Details
#to_h ⇒ Object
418 419 420 421 422 |
# File 'lib/basecamp/generated/types.rb', line 418 def to_h { "color" => @color, }.compact end |
#to_json(*args) ⇒ Object
424 425 426 |
# File 'lib/basecamp/generated/types.rb', line 424 def to_json(*args) to_h.to_json(*args) end |