Class: MicrosoftGraph::Models::RecurrencePattern
- Inherits:
-
Object
- Object
- MicrosoftGraph::Models::RecurrencePattern
- Includes:
- MicrosoftKiotaAbstractions::AdditionalDataHolder, MicrosoftKiotaAbstractions::Parsable
- Defined in:
- lib/models/recurrence_pattern.rb
Class Method Summary collapse
-
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value.
Instance Method Summary collapse
-
#additional_data ⇒ Object
Gets the additionalData property value.
-
#additional_data=(value) ⇒ Object
Sets the additionalData property value.
-
#day_of_month ⇒ Object
Gets the dayOfMonth property value.
-
#day_of_month=(value) ⇒ Object
Sets the dayOfMonth property value.
-
#days_of_week ⇒ Object
Gets the daysOfWeek property value.
-
#days_of_week=(value) ⇒ Object
Sets the daysOfWeek property value.
-
#first_day_of_week ⇒ Object
Gets the firstDayOfWeek property value.
-
#first_day_of_week=(value) ⇒ Object
Sets the firstDayOfWeek property value.
-
#get_field_deserializers ⇒ Object
The deserialization information for the current model.
-
#index ⇒ Object
Gets the index property value.
-
#index=(value) ⇒ Object
Sets the index property value.
-
#initialize ⇒ Object
constructor
Instantiates a new recurrencePattern and sets the default values.
-
#interval ⇒ Object
Gets the interval property value.
-
#interval=(value) ⇒ Object
Sets the interval property value.
-
#month ⇒ Object
Gets the month property value.
-
#month=(value) ⇒ Object
Sets the month property value.
-
#odata_type ⇒ Object
Gets the @odata.type property value.
-
#odata_type=(value) ⇒ Object
Sets the @odata.type property value.
-
#serialize(writer) ⇒ Object
Serializes information the current object.
-
#type ⇒ Object
Gets the type property value.
-
#type=(value) ⇒ Object
Sets the type property value.
Constructor Details
#initialize ⇒ Object
Instantiates a new recurrencePattern and sets the default values.
55 56 57 |
# File 'lib/models/recurrence_pattern.rb', line 55 def initialize() @additional_data = Hash.new end |
Class Method Details
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value
63 64 65 66 |
# File 'lib/models/recurrence_pattern.rb', line 63 def self.create_from_discriminator_value(parse_node) raise StandardError, 'parse_node cannot be null' if parse_node.nil? return RecurrencePattern.new end |
Instance Method Details
#additional_data ⇒ Object
Gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
40 41 42 |
# File 'lib/models/recurrence_pattern.rb', line 40 def additional_data return @additional_data end |
#additional_data=(value) ⇒ Object
Sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
48 49 50 |
# File 'lib/models/recurrence_pattern.rb', line 48 def additional_data=(value) @additional_data = value end |
#day_of_month ⇒ Object
Gets the dayOfMonth property value. The day of the month on which the event occurs. Required if type is absoluteMonthly or absoluteYearly.
71 72 73 |
# File 'lib/models/recurrence_pattern.rb', line 71 def day_of_month return @day_of_month end |
#day_of_month=(value) ⇒ Object
Sets the dayOfMonth property value. The day of the month on which the event occurs. Required if type is absoluteMonthly or absoluteYearly.
79 80 81 |
# File 'lib/models/recurrence_pattern.rb', line 79 def day_of_month=(value) @day_of_month = value end |
#days_of_week ⇒ Object
Gets the daysOfWeek property value. A collection of the days of the week on which the event occurs. The possible values are: sunday, monday, tuesday, wednesday, thursday, friday, saturday. If type is relativeMonthly or relativeYearly, and daysOfWeek specifies more than one day, the event falls on the first day that satisfies the pattern. Required if type is weekly, relativeMonthly, or relativeYearly.
86 87 88 |
# File 'lib/models/recurrence_pattern.rb', line 86 def days_of_week return @days_of_week end |
#days_of_week=(value) ⇒ Object
Sets the daysOfWeek property value. A collection of the days of the week on which the event occurs. The possible values are: sunday, monday, tuesday, wednesday, thursday, friday, saturday. If type is relativeMonthly or relativeYearly, and daysOfWeek specifies more than one day, the event falls on the first day that satisfies the pattern. Required if type is weekly, relativeMonthly, or relativeYearly.
94 95 96 |
# File 'lib/models/recurrence_pattern.rb', line 94 def days_of_week=(value) @days_of_week = value end |
#first_day_of_week ⇒ Object
Gets the firstDayOfWeek property value. The first day of the week. The possible values are: sunday, monday, tuesday, wednesday, thursday, friday, saturday. Default is sunday. Required if type is weekly.
101 102 103 |
# File 'lib/models/recurrence_pattern.rb', line 101 def first_day_of_week return @first_day_of_week end |
#first_day_of_week=(value) ⇒ Object
Sets the firstDayOfWeek property value. The first day of the week. The possible values are: sunday, monday, tuesday, wednesday, thursday, friday, saturday. Default is sunday. Required if type is weekly.
109 110 111 |
# File 'lib/models/recurrence_pattern.rb', line 109 def first_day_of_week=(value) @first_day_of_week = value end |
#get_field_deserializers ⇒ Object
The deserialization information for the current model
116 117 118 119 120 121 122 123 124 125 126 127 |
# File 'lib/models/recurrence_pattern.rb', line 116 def get_field_deserializers() return { "dayOfMonth" => lambda {|n| @day_of_month = n.get_number_value() }, "daysOfWeek" => lambda {|n| @days_of_week = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::DayOfWeek.create_from_discriminator_value(pn) }) }, "firstDayOfWeek" => lambda {|n| @first_day_of_week = n.get_enum_value(MicrosoftGraph::Models::DayOfWeek) }, "index" => lambda {|n| @index = n.get_enum_value(MicrosoftGraph::Models::WeekIndex) }, "interval" => lambda {|n| @interval = n.get_number_value() }, "month" => lambda {|n| @month = n.get_number_value() }, "@odata.type" => lambda {|n| @odata_type = n.get_string_value() }, "type" => lambda {|n| @type = n.get_enum_value(MicrosoftGraph::Models::RecurrencePatternType) }, } end |
#index ⇒ Object
Gets the index property value. Specifies on which instance of the allowed days specified in daysOfWeek the event occurs, counted from the first instance in the month. The possible values are: first, second, third, fourth, last. Default is first. Optional and used if type is relativeMonthly or relativeYearly.
132 133 134 |
# File 'lib/models/recurrence_pattern.rb', line 132 def index return @index end |
#index=(value) ⇒ Object
Sets the index property value. Specifies on which instance of the allowed days specified in daysOfWeek the event occurs, counted from the first instance in the month. The possible values are: first, second, third, fourth, last. Default is first. Optional and used if type is relativeMonthly or relativeYearly.
140 141 142 |
# File 'lib/models/recurrence_pattern.rb', line 140 def index=(value) @index = value end |
#interval ⇒ Object
Gets the interval property value. The number of units between occurrences, where units can be in days, weeks, months, or years, depending on the type. Required.
147 148 149 |
# File 'lib/models/recurrence_pattern.rb', line 147 def interval return @interval end |
#interval=(value) ⇒ Object
Sets the interval property value. The number of units between occurrences, where units can be in days, weeks, months, or years, depending on the type. Required.
155 156 157 |
# File 'lib/models/recurrence_pattern.rb', line 155 def interval=(value) @interval = value end |
#month ⇒ Object
Gets the month property value. The month in which the event occurs. This is a number from 1 to 12.
162 163 164 |
# File 'lib/models/recurrence_pattern.rb', line 162 def month return @month end |
#month=(value) ⇒ Object
Sets the month property value. The month in which the event occurs. This is a number from 1 to 12.
170 171 172 |
# File 'lib/models/recurrence_pattern.rb', line 170 def month=(value) @month = value end |
#odata_type ⇒ Object
Gets the @odata.type property value. The OdataType property
177 178 179 |
# File 'lib/models/recurrence_pattern.rb', line 177 def odata_type return @odata_type end |
#odata_type=(value) ⇒ Object
Sets the @odata.type property value. The OdataType property
185 186 187 |
# File 'lib/models/recurrence_pattern.rb', line 185 def odata_type=(value) @odata_type = value end |
#serialize(writer) ⇒ Object
Serializes information the current object
193 194 195 196 197 198 199 200 201 202 203 204 |
# File 'lib/models/recurrence_pattern.rb', line 193 def serialize(writer) raise StandardError, 'writer cannot be null' if writer.nil? writer.write_number_value("dayOfMonth", @day_of_month) writer.write_collection_of_object_values("daysOfWeek", @days_of_week) writer.write_enum_value("firstDayOfWeek", @first_day_of_week) writer.write_enum_value("index", @index) writer.write_number_value("interval", @interval) writer.write_number_value("month", @month) writer.write_string_value("@odata.type", @odata_type) writer.write_enum_value("type", @type) writer.write_additional_data(@additional_data) end |
#type ⇒ Object
Gets the type property value. The recurrence pattern type: daily, weekly, absoluteMonthly, relativeMonthly, absoluteYearly, relativeYearly. Required. For more information, see values of type property.
209 210 211 |
# File 'lib/models/recurrence_pattern.rb', line 209 def type return @type end |
#type=(value) ⇒ Object
Sets the type property value. The recurrence pattern type: daily, weekly, absoluteMonthly, relativeMonthly, absoluteYearly, relativeYearly. Required. For more information, see values of type property.
217 218 219 |
# File 'lib/models/recurrence_pattern.rb', line 217 def type=(value) @type = value end |