Class: MicrosoftGraph::Models::SynchronizationQuarantine

Inherits:
Object
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::AdditionalDataHolder, MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/synchronization_quarantine.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeObject

Instantiates a new synchronizationQuarantine and sets the default values.



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

def initialize()
    @additional_data = Hash.new
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 synchronization_quarantine

Raises:

  • (StandardError)


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

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

Instance Method Details

#additional_dataObject

Gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.

Returns:

  • a i_dictionary



38
39
40
# File 'lib/models/synchronization_quarantine.rb', line 38

def additional_data
    return @additional_data
end

#additional_data=(value) ⇒ Object

Sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.

Parameters:

  • value

    Value to set for the additionalData property.

Returns:

  • a void



46
47
48
# File 'lib/models/synchronization_quarantine.rb', line 46

def additional_data=(value)
    @additional_data = value
end

#current_beganObject

Gets the currentBegan property value. Date and time when the quarantine was last evaluated and imposed. 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.

Returns:

  • a date_time



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

def current_began
    return @current_began
end

#current_began=(value) ⇒ Object

Sets the currentBegan property value. Date and time when the quarantine was last evaluated and imposed. 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.

Parameters:

  • value

    Value to set for the currentBegan property.

Returns:

  • a void



77
78
79
# File 'lib/models/synchronization_quarantine.rb', line 77

def current_began=(value)
    @current_began = value
end

#errorObject

Gets the error property value. Describes the error(s) that occurred when putting the synchronization job into quarantine.

Returns:

  • a synchronization_error



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

def error
    return @error
end

#error=(value) ⇒ Object

Sets the error property value. Describes the error(s) that occurred when putting the synchronization job into quarantine.

Parameters:

  • value

    Value to set for the error property.

Returns:

  • a void



92
93
94
# File 'lib/models/synchronization_quarantine.rb', line 92

def error=(value)
    @error = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



99
100
101
102
103
104
105
106
107
108
109
# File 'lib/models/synchronization_quarantine.rb', line 99

def get_field_deserializers()
    return {
        "currentBegan" => lambda {|n| @current_began = n.get_date_time_value() },
        "error" => lambda {|n| @error = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::SynchronizationError.create_from_discriminator_value(pn) }) },
        "nextAttempt" => lambda {|n| @next_attempt = n.get_date_time_value() },
        "@odata.type" => lambda {|n| @odata_type = n.get_string_value() },
        "reason" => lambda {|n| @reason = n.get_enum_value(MicrosoftGraph::Models::QuarantineReason) },
        "seriesBegan" => lambda {|n| @series_began = n.get_date_time_value() },
        "seriesCount" => lambda {|n| @series_count = n.get_object_value(lambda {|pn| Int64.create_from_discriminator_value(pn) }) },
    }
end

#next_attemptObject

Gets the nextAttempt property value. Date and time when the next attempt to re-evaluate the quarantine will be made. 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.

Returns:

  • a date_time



114
115
116
# File 'lib/models/synchronization_quarantine.rb', line 114

def next_attempt
    return @next_attempt
end

#next_attempt=(value) ⇒ Object

Sets the nextAttempt property value. Date and time when the next attempt to re-evaluate the quarantine will be made. 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.

Parameters:

  • value

    Value to set for the nextAttempt property.

Returns:

  • a void



122
123
124
# File 'lib/models/synchronization_quarantine.rb', line 122

def next_attempt=(value)
    @next_attempt = value
end

#odata_typeObject

Gets the @odata.type property value. The OdataType property

Returns:

  • a string



129
130
131
# File 'lib/models/synchronization_quarantine.rb', line 129

def odata_type
    return @odata_type
end

#odata_type=(value) ⇒ Object

Sets the @odata.type property value. The OdataType property

Parameters:

  • value

    Value to set for the @odata.type property.

Returns:

  • a void



137
138
139
# File 'lib/models/synchronization_quarantine.rb', line 137

def odata_type=(value)
    @odata_type = value
end

#reasonObject

Gets the reason property value. The reason property

Returns:

  • a quarantine_reason



144
145
146
# File 'lib/models/synchronization_quarantine.rb', line 144

def reason
    return @reason
end

#reason=(value) ⇒ Object

Sets the reason property value. The reason property

Parameters:

  • value

    Value to set for the reason property.

Returns:

  • a void



152
153
154
# File 'lib/models/synchronization_quarantine.rb', line 152

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


160
161
162
163
164
165
166
167
168
169
170
# File 'lib/models/synchronization_quarantine.rb', line 160

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    writer.write_date_time_value("currentBegan", @current_began)
    writer.write_object_value("error", @error)
    writer.write_date_time_value("nextAttempt", @next_attempt)
    writer.write_string_value("@odata.type", @odata_type)
    writer.write_enum_value("reason", @reason)
    writer.write_date_time_value("seriesBegan", @series_began)
    writer.write_object_value("seriesCount", @series_count)
    writer.write_additional_data(@additional_data)
end

#series_beganObject

Gets the seriesBegan property value. Date and time when the quarantine was first imposed in this series (a series starts when a quarantine is first imposed, and is reset as soon as the quarantine is lifted). 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.

Returns:

  • a date_time



175
176
177
# File 'lib/models/synchronization_quarantine.rb', line 175

def series_began
    return @series_began
end

#series_began=(value) ⇒ Object

Sets the seriesBegan property value. Date and time when the quarantine was first imposed in this series (a series starts when a quarantine is first imposed, and is reset as soon as the quarantine is lifted). 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.

Parameters:

  • value

    Value to set for the seriesBegan property.

Returns:

  • a void



183
184
185
# File 'lib/models/synchronization_quarantine.rb', line 183

def series_began=(value)
    @series_began = value
end

#series_countObject

Gets the seriesCount property value. Number of times in this series the quarantine was re-evaluated and left in effect (a series starts when quarantine is first imposed, and is reset as soon as quarantine is lifted).

Returns:

  • a int64



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

def series_count
    return @series_count
end

#series_count=(value) ⇒ Object

Sets the seriesCount property value. Number of times in this series the quarantine was re-evaluated and left in effect (a series starts when quarantine is first imposed, and is reset as soon as quarantine is lifted).

Parameters:

  • value

    Value to set for the seriesCount property.

Returns:

  • a void



198
199
200
# File 'lib/models/synchronization_quarantine.rb', line 198

def series_count=(value)
    @series_count = value
end