Class: Azure::ContainerService::Profiles::Latest::Mgmt::ContainerServiceManagementClass

Inherits:
Object
  • Object
show all
Defined in:
lib/profiles/latest/modules/containerservice_profile_module.rb

Overview

ContainerServiceManagementClass

Direct Known Subclasses

Client

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ ContainerServiceManagementClass

Returns a new instance of ContainerServiceManagementClass.



145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 145

def initialize(options = {})
  if options.is_a?(Hash) && options.length == 0
    @options = setup_default_options
  else
    @options = options
  end

  reset!(options)

  @configurable = self
  @base_url = options[:base_url].nil? ? nil:options[:base_url]
  @options = options[:options].nil? ? nil:options[:options]

  @client_0 = Azure::ContainerService::Mgmt::V2017_07_01::ContainerServiceClient.new(configurable.credentials, base_url, options)
  if(@client_0.respond_to?(:subscription_id))
    @client_0.subscription_id = configurable.subscription_id
  end
  add_telemetry(@client_0)

  @client_1 = Azure::ContainerService::Mgmt::V2019_04_30::ContainerServiceClient.new(configurable.credentials, base_url, options)
  if(@client_1.respond_to?(:subscription_id))
    @client_1.subscription_id = configurable.subscription_id
  end
  add_telemetry(@client_1)
  @open_shift_managed_clusters = @client_1.open_shift_managed_clusters

  @client_2 = Azure::ContainerService::Mgmt::V2019_08_01::ContainerServiceClient.new(configurable.credentials, base_url, options)
  if(@client_2.respond_to?(:subscription_id))
    @client_2.subscription_id = configurable.subscription_id
  end
  add_telemetry(@client_2)
  @container_services = @client_2.container_services

  @client_3 = Azure::ContainerService::Mgmt::V2020_12_01::ContainerServiceClient.new(configurable.credentials, base_url, options)
  if(@client_3.respond_to?(:subscription_id))
    @client_3.subscription_id = configurable.subscription_id
  end
  add_telemetry(@client_3)
  @operations = @client_3.operations
  @managed_clusters = @client_3.managed_clusters
  @maintenance_configurations = @client_3.maintenance_configurations
  @agent_pools = @client_3.agent_pools
  @private_endpoint_connections = @client_3.private_endpoint_connections
  @private_link_resources = @client_3.private_link_resources
  @resolve_private_link_service_id = @client_3.resolve_private_link_service_id

  @model_classes = ModelClasses.new
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args) ⇒ Object



199
200
201
202
203
204
205
206
207
208
209
210
211
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 199

def method_missing(method, *args)
  if @client_3.respond_to?method
    @client_3.send(method, *args)
  elsif @client_2.respond_to?method
    @client_2.send(method, *args)
  elsif @client_1.respond_to?method
    @client_1.send(method, *args)
  elsif @client_0.respond_to?method
    @client_0.send(method, *args)
  else
    super
  end
end

Instance Attribute Details

#agent_poolsObject (readonly)

Returns the value of attribute agent_pools.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def agent_pools
  @agent_pools
end

#base_urlObject (readonly)

Returns the value of attribute base_url.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def base_url
  @base_url
end

#configurableObject (readonly)

Returns the value of attribute configurable.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def configurable
  @configurable
end

#container_servicesObject (readonly)

Returns the value of attribute container_services.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def container_services
  @container_services
end

#maintenance_configurationsObject (readonly)

Returns the value of attribute maintenance_configurations.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def maintenance_configurations
  @maintenance_configurations
end

#managed_clustersObject (readonly)

Returns the value of attribute managed_clusters.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def managed_clusters
  @managed_clusters
end

#model_classesObject (readonly)

Returns the value of attribute model_classes.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def model_classes
  @model_classes
end

#open_shift_managed_clustersObject (readonly)

Returns the value of attribute open_shift_managed_clusters.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def open_shift_managed_clusters
  @open_shift_managed_clusters
end

#operationsObject (readonly)

Returns the value of attribute operations.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def operations
  @operations
end

#optionsObject (readonly)

Returns the value of attribute options.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def options
  @options
end

#private_endpoint_connectionsObject (readonly)

Returns the value of attribute private_endpoint_connections.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def private_endpoint_connections
  @private_endpoint_connections
end

Returns the value of attribute private_link_resources.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def private_link_resources
  @private_link_resources
end

Returns the value of attribute resolve_private_link_service_id.



143
144
145
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 143

def resolve_private_link_service_id
  @resolve_private_link_service_id
end

Instance Method Details

#add_telemetry(client) ⇒ Object



194
195
196
197
# File 'lib/profiles/latest/modules/containerservice_profile_module.rb', line 194

def add_telemetry(client)
  profile_information = 'Profiles/Latest/ContainerService/Mgmt'
  client.add_user_agent_information(profile_information)
end