Class: MicrosoftGraph::Models::UserSettings

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



22
23
24
# File 'lib/models/user_settings.rb', line 22

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 user_settings

Raises:

  • (StandardError)


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

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

Instance Method Details

#contribution_to_content_discovery_as_organization_disabledObject

Gets the contributionToContentDiscoveryAsOrganizationDisabled property value. Reflects the organization level setting controlling delegate access to the trending API. When set to true, the organization doesn’t have access to Office Delve. The relevancy of the content displayed in Microsoft 365, for example in Suggested sites in SharePoint Home and the Discover view in OneDrive for Business is affected for the whole organization. This setting is read-only and can only be changed by administrators in the SharePoint admin center.

Returns:

  • a boolean



29
30
31
# File 'lib/models/user_settings.rb', line 29

def contribution_to_content_discovery_as_organization_disabled
    return @contribution_to_content_discovery_as_organization_disabled
end

#contribution_to_content_discovery_as_organization_disabled=(value) ⇒ Object

Sets the contributionToContentDiscoveryAsOrganizationDisabled property value. Reflects the organization level setting controlling delegate access to the trending API. When set to true, the organization doesn’t have access to Office Delve. The relevancy of the content displayed in Microsoft 365, for example in Suggested sites in SharePoint Home and the Discover view in OneDrive for Business is affected for the whole organization. This setting is read-only and can only be changed by administrators in the SharePoint admin center.

Parameters:

  • value

    Value to set for the contributionToContentDiscoveryAsOrganizationDisabled property.

Returns:

  • a void



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

def contribution_to_content_discovery_as_organization_disabled=(value)
    @contribution_to_content_discovery_as_organization_disabled = value
end

#contribution_to_content_discovery_disabledObject

Gets the contributionToContentDiscoveryDisabled property value. When set to true, the delegate access to the user’s trending API is disabled. When set to true, documents in the user’s Office Delve are disabled. When set to true, the relevancy of the content displayed in Microsoft 365, for example in Suggested sites in SharePoint Home and the Discover view in OneDrive for Business is affected. Users can control this setting in Office Delve.

Returns:

  • a boolean



44
45
46
# File 'lib/models/user_settings.rb', line 44

def contribution_to_content_discovery_disabled
    return @contribution_to_content_discovery_disabled
end

#contribution_to_content_discovery_disabled=(value) ⇒ Object

Sets the contributionToContentDiscoveryDisabled property value. When set to true, the delegate access to the user’s trending API is disabled. When set to true, documents in the user’s Office Delve are disabled. When set to true, the relevancy of the content displayed in Microsoft 365, for example in Suggested sites in SharePoint Home and the Discover view in OneDrive for Business is affected. Users can control this setting in Office Delve.

Parameters:

  • value

    Value to set for the contributionToContentDiscoveryDisabled property.

Returns:

  • a void



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

def contribution_to_content_discovery_disabled=(value)
    @contribution_to_content_discovery_disabled = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



68
69
70
71
72
73
74
# File 'lib/models/user_settings.rb', line 68

def get_field_deserializers()
    return super.merge({
        "contributionToContentDiscoveryAsOrganizationDisabled" => lambda {|n| @contribution_to_content_discovery_as_organization_disabled = n.get_boolean_value() },
        "contributionToContentDiscoveryDisabled" => lambda {|n| @contribution_to_content_discovery_disabled = n.get_boolean_value() },
        "shiftPreferences" => lambda {|n| @shift_preferences = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::ShiftPreferences.create_from_discriminator_value(pn) }) },
    })
end

#serialize(writer) ⇒ Object

Serializes information the current object

Parameters:

  • writer

    Serialization writer to use to serialize this model

Returns:

  • a void

Raises:

  • (StandardError)


80
81
82
83
84
85
86
# File 'lib/models/user_settings.rb', line 80

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_boolean_value("contributionToContentDiscoveryAsOrganizationDisabled", @contribution_to_content_discovery_as_organization_disabled)
    writer.write_boolean_value("contributionToContentDiscoveryDisabled", @contribution_to_content_discovery_disabled)
    writer.write_object_value("shiftPreferences", @shift_preferences)
end

#shift_preferencesObject

Gets the shiftPreferences property value. The shiftPreferences property

Returns:

  • a shift_preferences



91
92
93
# File 'lib/models/user_settings.rb', line 91

def shift_preferences
    return @shift_preferences
end

#shift_preferences=(value) ⇒ Object

Sets the shiftPreferences property value. The shiftPreferences property

Parameters:

  • value

    Value to set for the shiftPreferences property.

Returns:

  • a void



99
100
101
# File 'lib/models/user_settings.rb', line 99

def shift_preferences=(value)
    @shift_preferences = value
end