Class: Azure::Resources::Profiles::Latest::Mgmt::ResourcesManagementClass

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

Overview

ResourcesManagementClass

Direct Known Subclasses

Client

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ ResourcesManagementClass

Returns a new instance of ResourcesManagementClass.



91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 91

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::Resources::Mgmt::V2019_07_01::ResourceManagementClient.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)
  @operations = @client_0.operations
  @deployments = @client_0.deployments
  @providers = @client_0.providers
  @resources = @client_0.resources
  @resource_groups = @client_0.resource_groups
  @tags = @client_0.tags
  @deployment_operations = @client_0.deployment_operations

  @model_classes = ModelClasses.new
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args) ⇒ Object



125
126
127
128
129
130
131
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 125

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

Instance Attribute Details

#base_urlObject (readonly)

Returns the value of attribute base_url.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def base_url
  @base_url
end

#configurableObject (readonly)

Returns the value of attribute configurable.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def configurable
  @configurable
end

#deployment_operationsObject (readonly)

Returns the value of attribute deployment_operations.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def deployment_operations
  @deployment_operations
end

#deploymentsObject (readonly)

Returns the value of attribute deployments.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def deployments
  @deployments
end

#model_classesObject (readonly)

Returns the value of attribute model_classes.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def model_classes
  @model_classes
end

#operationsObject (readonly)

Returns the value of attribute operations.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def operations
  @operations
end

#optionsObject (readonly)

Returns the value of attribute options.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def options
  @options
end

#providersObject (readonly)

Returns the value of attribute providers.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def providers
  @providers
end

#resource_groupsObject (readonly)

Returns the value of attribute resource_groups.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def resource_groups
  @resource_groups
end

#resourcesObject (readonly)

Returns the value of attribute resources.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def resources
  @resources
end

#tagsObject (readonly)

Returns the value of attribute tags.



89
90
91
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 89

def tags
  @tags
end

Instance Method Details

#add_telemetry(client) ⇒ Object



120
121
122
123
# File 'lib/profiles/latest/modules/resources_profile_module.rb', line 120

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