Class: Azure::ARM::Web::Models::CsmSlotEntity

Inherits:
Object
  • Object
show all
Includes:
MsRestAzure
Defined in:
lib/azure_mgmt_web/models/csm_slot_entity.rb

Overview

Class containing deployment slot parameters

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#preserve_vnetBoolean

VNet to the slot during swap

Returns:

  • (Boolean)

    Get or set the flag indicating it should preserve



21
22
23
# File 'lib/azure_mgmt_web/models/csm_slot_entity.rb', line 21

def preserve_vnet
  @preserve_vnet
end

#target_slotString

operation

Returns:

  • (String)

    Set the destination deployment slot during swap



17
18
19
# File 'lib/azure_mgmt_web/models/csm_slot_entity.rb', line 17

def target_slot
  @target_slot
end

Class Method Details

.deserialize_object(object) ⇒ CsmSlotEntity

Deserializes given Ruby Hash into Model object.

Parameters:

  • object (Hash)

    Ruby Hash object to deserialize.

Returns:



53
54
55
56
57
58
59
60
61
62
63
64
# File 'lib/azure_mgmt_web/models/csm_slot_entity.rb', line 53

def self.deserialize_object(object)
  return if object.nil?
  output_object = CsmSlotEntity.new

  deserialized_property = object['targetSlot']
  output_object.target_slot = deserialized_property

  deserialized_property = object['preserveVnet']
  output_object.preserve_vnet = deserialized_property

  output_object
end

.serialize_object(object) ⇒ Hash

Serializes given Model object into Ruby Hash.

Parameters:

  • object

    Model object to serialize.

Returns:

  • (Hash)

    Serialized object in form of Ruby Hash.



35
36
37
38
39
40
41
42
43
44
45
46
# File 'lib/azure_mgmt_web/models/csm_slot_entity.rb', line 35

def self.serialize_object(object)
  object.validate
  output_object = {}

  serialized_property = object.target_slot
  output_object['targetSlot'] = serialized_property unless serialized_property.nil?

  serialized_property = object.preserve_vnet
  output_object['preserveVnet'] = serialized_property unless serialized_property.nil?

  output_object
end

Instance Method Details

#validateObject

Validate the object. Throws ValidationError if validation fails.



26
27
28
# File 'lib/azure_mgmt_web/models/csm_slot_entity.rb', line 26

def validate
  # Nothing to validate
end