Class: MicrosoftGraph::Models::ConversationThread

Inherits:
Entity
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/conversation_thread.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Entity

#additional_data, #additional_data=, #id, #id=, #odata_type, #odata_type=

Constructor Details

#initializeObject

Instantiates a new conversationThread and sets the default values.



56
57
58
# File 'lib/models/conversation_thread.rb', line 56

def initialize()
    super
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 conversation_thread

Raises:

  • (StandardError)


64
65
66
67
# File 'lib/models/conversation_thread.rb', line 64

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

Instance Method Details

#cc_recipientsObject

Gets the ccRecipients property value. The Cc: recipients for the thread. Returned only on $select.

Returns:

  • a recipient



41
42
43
# File 'lib/models/conversation_thread.rb', line 41

def cc_recipients
    return @cc_recipients
end

#cc_recipients=(value) ⇒ Object

Sets the ccRecipients property value. The Cc: recipients for the thread. Returned only on $select.

Parameters:

  • value

    Value to set for the ccRecipients property.

Returns:

  • a void



49
50
51
# File 'lib/models/conversation_thread.rb', line 49

def cc_recipients=(value)
    @cc_recipients = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



72
73
74
75
76
77
78
79
80
81
82
83
84
# File 'lib/models/conversation_thread.rb', line 72

def get_field_deserializers()
    return super.merge({
        "ccRecipients" => lambda {|n| @cc_recipients = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::Recipient.create_from_discriminator_value(pn) }) },
        "hasAttachments" => lambda {|n| @has_attachments = n.get_boolean_value() },
        "isLocked" => lambda {|n| @is_locked = n.get_boolean_value() },
        "lastDeliveredDateTime" => lambda {|n| @last_delivered_date_time = n.get_date_time_value() },
        "posts" => lambda {|n| @posts = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::Post.create_from_discriminator_value(pn) }) },
        "preview" => lambda {|n| @preview = n.get_string_value() },
        "toRecipients" => lambda {|n| @to_recipients = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::Recipient.create_from_discriminator_value(pn) }) },
        "topic" => lambda {|n| @topic = n.get_string_value() },
        "uniqueSenders" => lambda {|n| @unique_senders = n.get_collection_of_primitive_values(String) },
    })
end

#has_attachmentsObject

Gets the hasAttachments property value. Indicates whether any of the posts within this thread has at least one attachment. Returned by default.

Returns:

  • a boolean



89
90
91
# File 'lib/models/conversation_thread.rb', line 89

def has_attachments
    return @has_attachments
end

#has_attachments=(value) ⇒ Object

Sets the hasAttachments property value. Indicates whether any of the posts within this thread has at least one attachment. Returned by default.

Parameters:

  • value

    Value to set for the hasAttachments property.

Returns:

  • a void



97
98
99
# File 'lib/models/conversation_thread.rb', line 97

def has_attachments=(value)
    @has_attachments = value
end

#is_lockedObject

Gets the isLocked property value. Indicates if the thread is locked. Returned by default.

Returns:

  • a boolean



104
105
106
# File 'lib/models/conversation_thread.rb', line 104

def is_locked
    return @is_locked
end

#is_locked=(value) ⇒ Object

Sets the isLocked property value. Indicates if the thread is locked. Returned by default.

Parameters:

  • value

    Value to set for the isLocked property.

Returns:

  • a void



112
113
114
# File 'lib/models/conversation_thread.rb', line 112

def is_locked=(value)
    @is_locked = value
end

#last_delivered_date_timeObject

Gets the lastDeliveredDateTime property value. The Timestamp type represents date and time information using ISO 8601 format and is always in UTC time. For example, midnight UTC on Jan 1, 2014 is 2014-01-01T00:00:00Z.Returned by default.

Returns:

  • a date_time



119
120
121
# File 'lib/models/conversation_thread.rb', line 119

def last_delivered_date_time
    return @last_delivered_date_time
end

#last_delivered_date_time=(value) ⇒ Object

Sets the lastDeliveredDateTime property value. The Timestamp type represents date and time information using ISO 8601 format and is always in UTC time. For example, midnight UTC on Jan 1, 2014 is 2014-01-01T00:00:00Z.Returned by default.

Parameters:

  • value

    Value to set for the lastDeliveredDateTime property.

Returns:

  • a void



127
128
129
# File 'lib/models/conversation_thread.rb', line 127

def last_delivered_date_time=(value)
    @last_delivered_date_time = value
end

#postsObject

Gets the posts property value. The posts property

Returns:

  • a post



134
135
136
# File 'lib/models/conversation_thread.rb', line 134

def posts
    return @posts
end

#posts=(value) ⇒ Object

Sets the posts property value. The posts property

Parameters:

  • value

    Value to set for the posts property.

Returns:

  • a void



142
143
144
# File 'lib/models/conversation_thread.rb', line 142

def posts=(value)
    @posts = value
end

#previewObject

Gets the preview property value. A short summary from the body of the latest post in this conversation. Returned by default.

Returns:

  • a string



149
150
151
# File 'lib/models/conversation_thread.rb', line 149

def preview
    return @preview
end

#preview=(value) ⇒ Object

Sets the preview property value. A short summary from the body of the latest post in this conversation. Returned by default.

Parameters:

  • value

    Value to set for the preview property.

Returns:

  • a void



157
158
159
# File 'lib/models/conversation_thread.rb', line 157

def preview=(value)
    @preview = 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)


165
166
167
168
169
170
171
172
173
174
175
176
177
# File 'lib/models/conversation_thread.rb', line 165

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_collection_of_object_values("ccRecipients", @cc_recipients)
    writer.write_boolean_value("hasAttachments", @has_attachments)
    writer.write_boolean_value("isLocked", @is_locked)
    writer.write_date_time_value("lastDeliveredDateTime", @last_delivered_date_time)
    writer.write_collection_of_object_values("posts", @posts)
    writer.write_string_value("preview", @preview)
    writer.write_collection_of_object_values("toRecipients", @to_recipients)
    writer.write_string_value("topic", @topic)
    writer.write_collection_of_primitive_values("uniqueSenders", @unique_senders)
end

#to_recipientsObject

Gets the toRecipients property value. The To: recipients for the thread. Returned only on $select.

Returns:

  • a recipient



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

def to_recipients
    return @to_recipients
end

#to_recipients=(value) ⇒ Object

Sets the toRecipients property value. The To: recipients for the thread. Returned only on $select.

Parameters:

  • value

    Value to set for the toRecipients property.

Returns:

  • a void



190
191
192
# File 'lib/models/conversation_thread.rb', line 190

def to_recipients=(value)
    @to_recipients = value
end

#topicObject

Gets the topic property value. The topic of the conversation. This property can be set when the conversation is created, but it cannot be updated. Returned by default.

Returns:

  • a string



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

def topic
    return @topic
end

#topic=(value) ⇒ Object

Sets the topic property value. The topic of the conversation. This property can be set when the conversation is created, but it cannot be updated. Returned by default.

Parameters:

  • value

    Value to set for the topic property.

Returns:

  • a void



205
206
207
# File 'lib/models/conversation_thread.rb', line 205

def topic=(value)
    @topic = value
end

#unique_sendersObject

Gets the uniqueSenders property value. All the users that sent a message to this thread. Returned by default.

Returns:

  • a string



212
213
214
# File 'lib/models/conversation_thread.rb', line 212

def unique_senders
    return @unique_senders
end

#unique_senders=(value) ⇒ Object

Sets the uniqueSenders property value. All the users that sent a message to this thread. Returned by default.

Parameters:

  • value

    Value to set for the uniqueSenders property.

Returns:

  • a void



220
221
222
# File 'lib/models/conversation_thread.rb', line 220

def unique_senders=(value)
    @unique_senders = value
end