Class: MicrosoftGraph::Models::ScheduleItem

Inherits:
Object
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::AdditionalDataHolder, MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/schedule_item.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeObject

Instantiates a new scheduleItem and sets the default values.



52
53
54
# File 'lib/models/schedule_item.rb', line 52

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

Parameters:

  • parse_node

    The parse node to use to read the discriminator value and create the object

Returns:

  • a schedule_item

Raises:

  • (StandardError)


60
61
62
63
# File 'lib/models/schedule_item.rb', line 60

def self.create_from_discriminator_value(parse_node)
    raise StandardError, 'parse_node cannot be null' if parse_node.nil?
    return ScheduleItem.new
end

Instance Method Details

#additional_dataObject

Gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.

Returns:

  • a i_dictionary



37
38
39
# File 'lib/models/schedule_item.rb', line 37

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.

Parameters:

  • value

    Value to set for the additionalData property.

Returns:

  • a void



45
46
47
# File 'lib/models/schedule_item.rb', line 45

def additional_data=(value)
    @additional_data = value
end

#end_escapedObject

Gets the end property value. The date, time, and time zone that the corresponding event ends.

Returns:

  • a date_time_time_zone



68
69
70
# File 'lib/models/schedule_item.rb', line 68

def end_escaped
    return @end_escaped
end

#end_escaped=(value) ⇒ Object

Sets the end property value. The date, time, and time zone that the corresponding event ends.

Parameters:

  • value

    Value to set for the end property.

Returns:

  • a void



76
77
78
# File 'lib/models/schedule_item.rb', line 76

def end_escaped=(value)
    @end_escaped = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



83
84
85
86
87
88
89
90
91
92
93
# File 'lib/models/schedule_item.rb', line 83

def get_field_deserializers()
    return {
        "end" => lambda {|n| @end_escaped = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::DateTimeTimeZone.create_from_discriminator_value(pn) }) },
        "isPrivate" => lambda {|n| @is_private = n.get_boolean_value() },
        "location" => lambda {|n| @location = n.get_string_value() },
        "@odata.type" => lambda {|n| @odata_type = n.get_string_value() },
        "start" => lambda {|n| @start = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::DateTimeTimeZone.create_from_discriminator_value(pn) }) },
        "status" => lambda {|n| @status = n.get_enum_value(MicrosoftGraph::Models::FreeBusyStatus) },
        "subject" => lambda {|n| @subject = n.get_string_value() },
    }
end

#is_privateObject

Gets the isPrivate property value. The sensitivity of the corresponding event. True if the event is marked private, false otherwise. Optional.

Returns:

  • a boolean



98
99
100
# File 'lib/models/schedule_item.rb', line 98

def is_private
    return @is_private
end

#is_private=(value) ⇒ Object

Sets the isPrivate property value. The sensitivity of the corresponding event. True if the event is marked private, false otherwise. Optional.

Parameters:

  • value

    Value to set for the isPrivate property.

Returns:

  • a void



106
107
108
# File 'lib/models/schedule_item.rb', line 106

def is_private=(value)
    @is_private = value
end

#locationObject

Gets the location property value. The location where the corresponding event is held or attended from. Optional.

Returns:

  • a string



113
114
115
# File 'lib/models/schedule_item.rb', line 113

def location
    return @location
end

#location=(value) ⇒ Object

Sets the location property value. The location where the corresponding event is held or attended from. Optional.

Parameters:

  • value

    Value to set for the location property.

Returns:

  • a void



121
122
123
# File 'lib/models/schedule_item.rb', line 121

def location=(value)
    @location = value
end

#odata_typeObject

Gets the @odata.type property value. The OdataType property

Returns:

  • a string



128
129
130
# File 'lib/models/schedule_item.rb', line 128

def odata_type
    return @odata_type
end

#odata_type=(value) ⇒ Object

Sets the @odata.type property value. The OdataType property

Parameters:

  • value

    Value to set for the @odata.type property.

Returns:

  • a void



136
137
138
# File 'lib/models/schedule_item.rb', line 136

def odata_type=(value)
    @odata_type = value
end

#serialize(writer) ⇒ Object

Serializes information the current object

Parameters:

  • writer

    Serialization writer to use to serialize this model

Returns:

  • a void

Raises:

  • (StandardError)


144
145
146
147
148
149
150
151
152
153
154
# File 'lib/models/schedule_item.rb', line 144

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    writer.write_object_value("end", @end_escaped)
    writer.write_boolean_value("isPrivate", @is_private)
    writer.write_string_value("location", @location)
    writer.write_string_value("@odata.type", @odata_type)
    writer.write_object_value("start", @start)
    writer.write_enum_value("status", @status)
    writer.write_string_value("subject", @subject)
    writer.write_additional_data(@additional_data)
end

#startObject

Gets the start property value. The date, time, and time zone that the corresponding event starts.

Returns:

  • a date_time_time_zone



159
160
161
# File 'lib/models/schedule_item.rb', line 159

def start
    return @start
end

#start=(value) ⇒ Object

Sets the start property value. The date, time, and time zone that the corresponding event starts.

Parameters:

  • value

    Value to set for the start property.

Returns:

  • a void



167
168
169
# File 'lib/models/schedule_item.rb', line 167

def start=(value)
    @start = value
end

#statusObject

Gets the status property value. The availability status of the user or resource during the corresponding event. The possible values are: free, tentative, busy, oof, workingElsewhere, unknown.

Returns:

  • a free_busy_status



174
175
176
# File 'lib/models/schedule_item.rb', line 174

def status
    return @status
end

#status=(value) ⇒ Object

Sets the status property value. The availability status of the user or resource during the corresponding event. The possible values are: free, tentative, busy, oof, workingElsewhere, unknown.

Parameters:

  • value

    Value to set for the status property.

Returns:

  • a void



182
183
184
# File 'lib/models/schedule_item.rb', line 182

def status=(value)
    @status = value
end

#subjectObject

Gets the subject property value. The corresponding event’s subject line. Optional.

Returns:

  • a string



189
190
191
# File 'lib/models/schedule_item.rb', line 189

def subject
    return @subject
end

#subject=(value) ⇒ Object

Sets the subject property value. The corresponding event’s subject line. Optional.

Parameters:

  • value

    Value to set for the subject property.

Returns:

  • a void



197
198
199
# File 'lib/models/schedule_item.rb', line 197

def subject=(value)
    @subject = value
end