Class: Basecamp::Types::LineupMarker
- Inherits:
-
Object
- Object
- Basecamp::Types::LineupMarker
- Includes:
- TypeHelpers
- Defined in:
- lib/basecamp/generated/types.rb
Overview
LineupMarker
Instance Attribute Summary collapse
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#date ⇒ Object
Returns the value of attribute date.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#updated_at ⇒ Object
Returns the value of attribute updated_at.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ LineupMarker
constructor
A new instance of LineupMarker.
- #to_h ⇒ Object
- #to_json(*args) ⇒ Object
Constructor Details
#initialize(data = {}) ⇒ LineupMarker
Returns a new instance of LineupMarker.
1995 1996 1997 1998 1999 2000 2001 |
# File 'lib/basecamp/generated/types.rb', line 1995 def initialize(data = {}) @created_at = parse_datetime(data["created_at"]) @date = data["date"] @id = parse_integer(data["id"]) @name = data["name"] @updated_at = parse_datetime(data["updated_at"]) end |
Instance Attribute Details
#created_at ⇒ Object
Returns the value of attribute created_at.
1988 1989 1990 |
# File 'lib/basecamp/generated/types.rb', line 1988 def created_at @created_at end |
#date ⇒ Object
Returns the value of attribute date.
1988 1989 1990 |
# File 'lib/basecamp/generated/types.rb', line 1988 def date @date end |
#id ⇒ Object
Returns the value of attribute id.
1988 1989 1990 |
# File 'lib/basecamp/generated/types.rb', line 1988 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
1988 1989 1990 |
# File 'lib/basecamp/generated/types.rb', line 1988 def name @name end |
#updated_at ⇒ Object
Returns the value of attribute updated_at.
1988 1989 1990 |
# File 'lib/basecamp/generated/types.rb', line 1988 def updated_at @updated_at end |
Class Method Details
.required_fields ⇒ Array<Symbol>
1991 1992 1993 |
# File 'lib/basecamp/generated/types.rb', line 1991 def self.required_fields %i[created_at date id name updated_at].freeze end |
Instance Method Details
#to_h ⇒ Object
2003 2004 2005 2006 2007 2008 2009 2010 2011 |
# File 'lib/basecamp/generated/types.rb', line 2003 def to_h { "created_at" => @created_at, "date" => @date, "id" => @id, "name" => @name, "updated_at" => @updated_at, }.compact end |
#to_json(*args) ⇒ Object
2013 2014 2015 |
# File 'lib/basecamp/generated/types.rb', line 2013 def to_json(*args) to_h.to_json(*args) end |