Class: MicrosoftGraph::Models::BrowserSharedCookie

Inherits:
Entity
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/browser_shared_cookie.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 browserSharedCookie and sets the default values.



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

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 browser_shared_cookie

Raises:

  • (StandardError)


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

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

Instance Method Details

#commentObject

Gets the comment property value. The comment for the shared cookie.

Returns:

  • a string



50
51
52
# File 'lib/models/browser_shared_cookie.rb', line 50

def comment
    return @comment
end

#comment=(value) ⇒ Object

Sets the comment property value. The comment for the shared cookie.

Parameters:

  • value

    Value to set for the comment property.

Returns:

  • a void



58
59
60
# File 'lib/models/browser_shared_cookie.rb', line 58

def comment=(value)
    @comment = value
end

#created_date_timeObject

Gets the createdDateTime property value. The date and time when the shared cookie was created.

Returns:

  • a date_time



72
73
74
# File 'lib/models/browser_shared_cookie.rb', line 72

def created_date_time
    return @created_date_time
end

#created_date_time=(value) ⇒ Object

Sets the createdDateTime property value. The date and time when the shared cookie was created.

Parameters:

  • value

    Value to set for the createdDateTime property.

Returns:

  • a void



80
81
82
# File 'lib/models/browser_shared_cookie.rb', line 80

def created_date_time=(value)
    @created_date_time = value
end

#deleted_date_timeObject

Gets the deletedDateTime property value. The date and time when the shared cookie was deleted.

Returns:

  • a date_time



96
97
98
# File 'lib/models/browser_shared_cookie.rb', line 96

def deleted_date_time
    return @deleted_date_time
end

#deleted_date_time=(value) ⇒ Object

Sets the deletedDateTime property value. The date and time when the shared cookie was deleted.

Parameters:

  • value

    Value to set for the deletedDateTime property.

Returns:

  • a void



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

def deleted_date_time=(value)
    @deleted_date_time = value
end

#display_nameObject

Gets the displayName property value. The name of the cookie.

Returns:

  • a string



111
112
113
# File 'lib/models/browser_shared_cookie.rb', line 111

def display_name
    return @display_name
end

#display_name=(value) ⇒ Object

Sets the displayName property value. The name of the cookie.

Parameters:

  • value

    Value to set for the displayName property.

Returns:

  • a void



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

def display_name=(value)
    @display_name = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
# File 'lib/models/browser_shared_cookie.rb', line 126

def get_field_deserializers()
    return super.merge({
        "comment" => lambda {|n| @comment = n.get_string_value() },
        "createdDateTime" => lambda {|n| @created_date_time = n.get_date_time_value() },
        "deletedDateTime" => lambda {|n| @deleted_date_time = n.get_date_time_value() },
        "displayName" => lambda {|n| @display_name = n.get_string_value() },
        "history" => lambda {|n| @history = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::BrowserSharedCookieHistory.create_from_discriminator_value(pn) }) },
        "hostOnly" => lambda {|n| @host_only = n.get_boolean_value() },
        "hostOrDomain" => lambda {|n| @host_or_domain = n.get_string_value() },
        "lastModifiedBy" => lambda {|n| @last_modified_by = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::IdentitySet.create_from_discriminator_value(pn) }) },
        "lastModifiedDateTime" => lambda {|n| @last_modified_date_time = n.get_date_time_value() },
        "path" => lambda {|n| @path = n.get_string_value() },
        "sourceEnvironment" => lambda {|n| @source_environment = n.get_enum_value(MicrosoftGraph::Models::BrowserSharedCookieSourceEnvironment) },
        "status" => lambda {|n| @status = n.get_enum_value(MicrosoftGraph::Models::BrowserSharedCookieStatus) },
    })
end

#historyObject

Gets the history property value. The history of modifications applied to the cookie.

Returns:

  • a browser_shared_cookie_history



146
147
148
# File 'lib/models/browser_shared_cookie.rb', line 146

def history
    return @history
end

#history=(value) ⇒ Object

Sets the history property value. The history of modifications applied to the cookie.

Parameters:

  • value

    Value to set for the history property.

Returns:

  • a void



154
155
156
# File 'lib/models/browser_shared_cookie.rb', line 154

def history=(value)
    @history = value
end

#host_onlyObject

Gets the hostOnly property value. Controls whether a cookie is a host-only or domain cookie.

Returns:

  • a boolean



161
162
163
# File 'lib/models/browser_shared_cookie.rb', line 161

def host_only
    return @host_only
end

#host_only=(value) ⇒ Object

Sets the hostOnly property value. Controls whether a cookie is a host-only or domain cookie.

Parameters:

  • value

    Value to set for the hostOnly property.

Returns:

  • a void



169
170
171
# File 'lib/models/browser_shared_cookie.rb', line 169

def host_only=(value)
    @host_only = value
end

#host_or_domainObject

Gets the hostOrDomain property value. The URL of the cookie.

Returns:

  • a string



176
177
178
# File 'lib/models/browser_shared_cookie.rb', line 176

def host_or_domain
    return @host_or_domain
end

#host_or_domain=(value) ⇒ Object

Sets the hostOrDomain property value. The URL of the cookie.

Parameters:

  • value

    Value to set for the hostOrDomain property.

Returns:

  • a void



184
185
186
# File 'lib/models/browser_shared_cookie.rb', line 184

def host_or_domain=(value)
    @host_or_domain = value
end

#last_modified_byObject

Gets the lastModifiedBy property value. The user who last modified the cookie.

Returns:

  • a identity_set



191
192
193
# File 'lib/models/browser_shared_cookie.rb', line 191

def last_modified_by
    return @last_modified_by
end

#last_modified_by=(value) ⇒ Object

Sets the lastModifiedBy property value. The user who last modified the cookie.

Parameters:

  • value

    Value to set for the lastModifiedBy property.

Returns:

  • a void



199
200
201
# File 'lib/models/browser_shared_cookie.rb', line 199

def last_modified_by=(value)
    @last_modified_by = value
end

#last_modified_date_timeObject

Gets the lastModifiedDateTime property value. The date and time when the cookie was last modified.

Returns:

  • a date_time



206
207
208
# File 'lib/models/browser_shared_cookie.rb', line 206

def last_modified_date_time
    return @last_modified_date_time
end

#last_modified_date_time=(value) ⇒ Object

Sets the lastModifiedDateTime property value. The date and time when the cookie was last modified.

Parameters:

  • value

    Value to set for the lastModifiedDateTime property.

Returns:

  • a void



214
215
216
# File 'lib/models/browser_shared_cookie.rb', line 214

def last_modified_date_time=(value)
    @last_modified_date_time = value
end

#pathObject

Gets the path property value. The path of the cookie.

Returns:

  • a string



221
222
223
# File 'lib/models/browser_shared_cookie.rb', line 221

def path
    return @path
end

#path=(value) ⇒ Object

Sets the path property value. The path of the cookie.

Parameters:

  • value

    Value to set for the path property.

Returns:

  • a void



229
230
231
# File 'lib/models/browser_shared_cookie.rb', line 229

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


237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
# File 'lib/models/browser_shared_cookie.rb', line 237

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_string_value("comment", @comment)
    writer.write_date_time_value("createdDateTime", @created_date_time)
    writer.write_date_time_value("deletedDateTime", @deleted_date_time)
    writer.write_string_value("displayName", @display_name)
    writer.write_collection_of_object_values("history", @history)
    writer.write_boolean_value("hostOnly", @host_only)
    writer.write_string_value("hostOrDomain", @host_or_domain)
    writer.write_object_value("lastModifiedBy", @last_modified_by)
    writer.write_date_time_value("lastModifiedDateTime", @last_modified_date_time)
    writer.write_string_value("path", @path)
    writer.write_enum_value("sourceEnvironment", @source_environment)
    writer.write_enum_value("status", @status)
end

#source_environmentObject

Gets the sourceEnvironment property value. The sourceEnvironment property

Returns:

  • a browser_shared_cookie_source_environment



257
258
259
# File 'lib/models/browser_shared_cookie.rb', line 257

def source_environment
    return @source_environment
end

#source_environment=(value) ⇒ Object

Sets the sourceEnvironment property value. The sourceEnvironment property

Parameters:

  • value

    Value to set for the sourceEnvironment property.

Returns:

  • a void



265
266
267
# File 'lib/models/browser_shared_cookie.rb', line 265

def source_environment=(value)
    @source_environment = value
end

#statusObject

Gets the status property value. The status property

Returns:

  • a browser_shared_cookie_status



272
273
274
# File 'lib/models/browser_shared_cookie.rb', line 272

def status
    return @status
end

#status=(value) ⇒ Object

Sets the status property value. The status property

Parameters:

  • value

    Value to set for the status property.

Returns:

  • a void



280
281
282
# File 'lib/models/browser_shared_cookie.rb', line 280

def status=(value)
    @status = value
end