Class: Azure::ARM::Web::Models::SlotConfigNames

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

Overview

Class containing names for connection strings and application settings to be marked as sticky to the slot and not moved during swap operation This is valid for all deployment slots under the site

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#app_setting_namesArray<String>

Returns List of application settings names.

Returns:

  • (Array<String>)

    List of application settings names



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

def app_setting_names
  @app_setting_names
end

#connection_string_namesArray<String>

Returns List of connection string names.

Returns:

  • (Array<String>)

    List of connection string names



19
20
21
# File 'lib/azure_mgmt_web/models/slot_config_names.rb', line 19

def connection_string_names
  @connection_string_names
end

Class Method Details

.deserialize_object(object) ⇒ SlotConfigNames

Deserializes given Ruby Hash into Model object.

Parameters:

  • object (Hash)

    Ruby Hash object to deserialize.

Returns:



55
56
57
58
59
60
61
62
63
64
65
66
# File 'lib/azure_mgmt_web/models/slot_config_names.rb', line 55

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

  deserialized_property = object['connectionStringNames']
  output_object.connection_string_names = deserialized_property

  deserialized_property = object['appSettingNames']
  output_object.app_setting_names = 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.



37
38
39
40
41
42
43
44
45
46
47
48
# File 'lib/azure_mgmt_web/models/slot_config_names.rb', line 37

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

  serialized_property = object.connection_string_names
  output_object['connectionStringNames'] = serialized_property unless serialized_property.nil?

  serialized_property = object.app_setting_names
  output_object['appSettingNames'] = serialized_property unless serialized_property.nil?

  output_object
end

Instance Method Details

#validateObject

Validate the object. Throws ValidationError if validation fails.



27
28
29
30
# File 'lib/azure_mgmt_web/models/slot_config_names.rb', line 27

def validate
  @connection_string_names.each{ |e| e.validate if e.respond_to?(:validate) } unless @connection_string_names.nil?
  @app_setting_names.each{ |e| e.validate if e.respond_to?(:validate) } unless @app_setting_names.nil?
end