Class: MicrosoftGraph::Models::MicrosoftAuthenticatorAuthenticationMethod

Inherits:
AuthenticationMethod show all
Includes:
MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/microsoft_authenticator_authentication_method.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 microsoftAuthenticatorAuthenticationMethod and sets the default values.



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

def initialize()
    super
    @odata_type = "#microsoft.graph.microsoftAuthenticatorAuthenticationMethod"
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 microsoft_authenticator_authentication_method

Raises:

  • (StandardError)


53
54
55
56
# File 'lib/models/microsoft_authenticator_authentication_method.rb', line 53

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

Instance Method Details

#created_date_timeObject

Gets the createdDateTime property value. The date and time that this app was registered. This property is null if the device is not registered for passwordless Phone Sign-In.

Returns:

  • a date_time



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

def created_date_time
    return @created_date_time
end

#created_date_time=(value) ⇒ Object

Sets the createdDateTime property value. The date and time that this app was registered. This property is null if the device is not registered for passwordless Phone Sign-In.

Parameters:

  • value

    Value to set for the createdDateTime property.

Returns:

  • a void



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

def created_date_time=(value)
    @created_date_time = value
end

#deviceObject

Gets the device property value. The registered device on which Microsoft Authenticator resides. This property is null if the device is not registered for passwordless Phone Sign-In.

Returns:

  • a device



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

def device
    return @device
end

#device=(value) ⇒ Object

Sets the device property value. The registered device on which Microsoft Authenticator resides. This property is null if the device is not registered for passwordless Phone Sign-In.

Parameters:

  • value

    Value to set for the device property.

Returns:

  • a void



69
70
71
# File 'lib/models/microsoft_authenticator_authentication_method.rb', line 69

def device=(value)
    @device = value
end

#device_tagObject

Gets the deviceTag property value. Tags containing app metadata.

Returns:

  • a string



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

def device_tag
    return @device_tag
end

#device_tag=(value) ⇒ Object

Sets the deviceTag property value. Tags containing app metadata.

Parameters:

  • value

    Value to set for the deviceTag property.

Returns:

  • a void



84
85
86
# File 'lib/models/microsoft_authenticator_authentication_method.rb', line 84

def device_tag=(value)
    @device_tag = value
end

#display_nameObject

Gets the displayName property value. The name of the device on which this app is registered.

Returns:

  • a string



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

def display_name
    return @display_name
end

#display_name=(value) ⇒ Object

Sets the displayName property value. The name of the device on which this app is registered.

Parameters:

  • value

    Value to set for the displayName property.

Returns:

  • a void



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

def display_name=(value)
    @display_name = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



106
107
108
109
110
111
112
113
114
# File 'lib/models/microsoft_authenticator_authentication_method.rb', line 106

def get_field_deserializers()
    return super.merge({
        "createdDateTime" => lambda {|n| @created_date_time = n.get_date_time_value() },
        "device" => lambda {|n| @device = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Device.create_from_discriminator_value(pn) }) },
        "deviceTag" => lambda {|n| @device_tag = n.get_string_value() },
        "displayName" => lambda {|n| @display_name = n.get_string_value() },
        "phoneAppVersion" => lambda {|n| @phone_app_version = n.get_string_value() },
    })
end

#phone_app_versionObject

Gets the phoneAppVersion property value. Numerical version of this instance of the Authenticator app.

Returns:

  • a string



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

def phone_app_version
    return @phone_app_version
end

#phone_app_version=(value) ⇒ Object

Sets the phoneAppVersion property value. Numerical version of this instance of the Authenticator app.

Parameters:

  • value

    Value to set for the phoneAppVersion property.

Returns:

  • a void



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

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


135
136
137
138
139
140
141
142
143
# File 'lib/models/microsoft_authenticator_authentication_method.rb', line 135

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    super
    writer.write_date_time_value("createdDateTime", @created_date_time)
    writer.write_object_value("device", @device)
    writer.write_string_value("deviceTag", @device_tag)
    writer.write_string_value("displayName", @display_name)
    writer.write_string_value("phoneAppVersion", @phone_app_version)
end