Class: MicrosoftGraph::Models::ConditionalAccessTemplate

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



25
26
27
# File 'lib/models/conditional_access_template.rb', line 25

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 conditional_access_template

Raises:

  • (StandardError)


33
34
35
36
# File 'lib/models/conditional_access_template.rb', line 33

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

Instance Method Details

#descriptionObject

Gets the description property value. The user-friendly name of the template.

Returns:

  • a string



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

def description
    return @description
end

#description=(value) ⇒ Object

Sets the description property value. The user-friendly name of the template.

Parameters:

  • value

    Value to set for the description property.

Returns:

  • a void



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

def description=(value)
    @description = value
end

#detailsObject

Gets the details property value. The details property

Returns:

  • a conditional_access_policy_detail



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

def details
    return @details
end

#details=(value) ⇒ Object

Sets the details property value. The details property

Parameters:

  • value

    Value to set for the details property.

Returns:

  • a void



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

def details=(value)
    @details = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



71
72
73
74
75
76
77
78
# File 'lib/models/conditional_access_template.rb', line 71

def get_field_deserializers()
    return super.merge({
        "description" => lambda {|n| @description = n.get_string_value() },
        "details" => lambda {|n| @details = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::ConditionalAccessPolicyDetail.create_from_discriminator_value(pn) }) },
        "name" => lambda {|n| @name = n.get_string_value() },
        "scenarios" => lambda {|n| @scenarios = n.get_enum_value(MicrosoftGraph::Models::TemplateScenarios) },
    })
end

#nameObject

Gets the name property value. The user-friendly name of the template.

Returns:

  • a string



83
84
85
# File 'lib/models/conditional_access_template.rb', line 83

def name
    return @name
end

#name=(value) ⇒ Object

Sets the name property value. The user-friendly name of the template.

Parameters:

  • value

    Value to set for the name property.

Returns:

  • a void



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

def name=(value)
    @name = value
end

#scenariosObject

Gets the scenarios property value. The scenarios property

Returns:

  • a template_scenarios



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

def scenarios
    return @scenarios
end

#scenarios=(value) ⇒ Object

Sets the scenarios property value. The scenarios property

Parameters:

  • value

    Value to set for the scenarios property.

Returns:

  • a void



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

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


114
115
116
117
118
119
120
121
# File 'lib/models/conditional_access_template.rb', line 114

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_string_value("description", @description)
    writer.write_object_value("details", @details)
    writer.write_string_value("name", @name)
    writer.write_enum_value("scenarios", @scenarios)
end