Class: Basecamp::Types::QuestionSchedule
- Inherits:
-
Object
- Object
- Basecamp::Types::QuestionSchedule
- Includes:
- TypeHelpers
- Defined in:
- lib/basecamp/generated/types.rb
Overview
QuestionSchedule
Instance Attribute Summary collapse
-
#days ⇒ Object
Returns the value of attribute days.
-
#end_date ⇒ Object
Returns the value of attribute end_date.
-
#frequency ⇒ Object
Returns the value of attribute frequency.
-
#hour ⇒ Object
Returns the value of attribute hour.
-
#minute ⇒ Object
Returns the value of attribute minute.
-
#month_interval ⇒ Object
Returns the value of attribute month_interval.
-
#start_date ⇒ Object
Returns the value of attribute start_date.
-
#week_instance ⇒ Object
Returns the value of attribute week_instance.
-
#week_interval ⇒ Object
Returns the value of attribute week_interval.
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ QuestionSchedule
constructor
A new instance of QuestionSchedule.
- #to_h ⇒ Object
- #to_json(*args) ⇒ Object
Constructor Details
#initialize(data = {}) ⇒ QuestionSchedule
Returns a new instance of QuestionSchedule.
3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 |
# File 'lib/basecamp/generated/types.rb', line 3011 def initialize(data = {}) @days = data["days"] @end_date = data["end_date"] @frequency = data["frequency"] @hour = parse_integer(data["hour"]) @minute = parse_integer(data["minute"]) @month_interval = parse_integer(data["month_interval"]) @start_date = data["start_date"] @week_instance = parse_integer(data["week_instance"]) @week_interval = parse_integer(data["week_interval"]) end |
Instance Attribute Details
#days ⇒ Object
Returns the value of attribute days.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def days @days end |
#end_date ⇒ Object
Returns the value of attribute end_date.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def end_date @end_date end |
#frequency ⇒ Object
Returns the value of attribute frequency.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def frequency @frequency end |
#hour ⇒ Object
Returns the value of attribute hour.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def hour @hour end |
#minute ⇒ Object
Returns the value of attribute minute.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def minute @minute end |
#month_interval ⇒ Object
Returns the value of attribute month_interval.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def month_interval @month_interval end |
#start_date ⇒ Object
Returns the value of attribute start_date.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def start_date @start_date end |
#week_instance ⇒ Object
Returns the value of attribute week_instance.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def week_instance @week_instance end |
#week_interval ⇒ Object
Returns the value of attribute week_interval.
3009 3010 3011 |
# File 'lib/basecamp/generated/types.rb', line 3009 def week_interval @week_interval end |
Instance Method Details
#to_h ⇒ Object
3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 |
# File 'lib/basecamp/generated/types.rb', line 3023 def to_h { "days" => @days, "end_date" => @end_date, "frequency" => @frequency, "hour" => @hour, "minute" => @minute, "month_interval" => @month_interval, "start_date" => @start_date, "week_instance" => @week_instance, "week_interval" => @week_interval, }.compact end |
#to_json(*args) ⇒ Object
3037 3038 3039 |
# File 'lib/basecamp/generated/types.rb', line 3037 def to_json(*args) to_h.to_json(*args) end |