azure_mgmt_cognitive_services 0.15.2 → 0.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services.rb +44 -0
  3. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/cognitive_services_accounts.rb +1018 -0
  4. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/cognitive_services_management_client.rb +131 -0
  5. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_account.rb +163 -0
  6. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_account_create_parameters.rb +112 -0
  7. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_account_enumerate_skus_result.rb +58 -0
  8. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_account_keys.rb +57 -0
  9. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_account_list_result.rb +57 -0
  10. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_account_update_parameters.rb +70 -0
  11. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/cognitive_services_resource_and_sku.rb +59 -0
  12. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/error.rb +48 -0
  13. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/error_body.rb +58 -0
  14. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/key_name.rb +16 -0
  15. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/kind.rb +31 -0
  16. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/provisioning_state.rb +18 -0
  17. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/regenerate_key_parameters.rb +48 -0
  18. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/sku.rb +62 -0
  19. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/sku_name.rb +25 -0
  20. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/models/sku_tier.rb +17 -0
  21. data/lib/2016-02-01-preview/generated/azure_mgmt_cognitive_services/module_definition.rb +9 -0
  22. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/accounts.rb +72 -67
  23. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/check_sku_availability.rb +15 -13
  24. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/cognitive_services_management_client.rb +4 -1
  25. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/models/check_sku_availability_parameter.rb +6 -5
  26. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/models/check_sku_availability_result.rb +6 -5
  27. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/models/cognitive_services_account.rb +2 -3
  28. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/models/cognitive_services_account_create_parameters.rb +4 -2
  29. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/models/kind.rb +4 -0
  30. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/models/provisioning_state.rb +2 -0
  31. data/lib/2017-04-18/generated/azure_mgmt_cognitive_services/operations.rb +15 -13
  32. data/lib/azure_mgmt_cognitive_services.rb +1 -0
  33. data/lib/profiles/latest/cognitiveservices_latest_profile_client.rb +28 -9
  34. data/lib/profiles/latest/cognitiveservices_module_definition.rb +0 -1
  35. data/lib/profiles/latest/modules/cognitiveservices_profile_module.rb +96 -77
  36. data/lib/version.rb +1 -1
  37. metadata +22 -2
@@ -27,8 +27,9 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
27
27
  # @param location [String] Resource location.
28
28
  # @param skus [Array<SkuName>] The SKU of the resource.
29
29
  # @param kind [Kind] The Kind of the resource. Possible values include:
30
- # 'Academic', 'Bing.Autosuggest', 'Bing.Search', 'Bing.Speech',
31
- # 'Bing.SpellCheck', 'ComputerVision', 'ContentModerator', 'CustomSpeech',
30
+ # 'Academic', 'Bing.Autosuggest', 'Bing.Autosuggest.v7', 'Bing.CustomSearch',
31
+ # 'Bing.Search', 'Bing.Search.v7', 'Bing.Speech', 'Bing.SpellCheck',
32
+ # 'Bing.SpellCheck.v7', 'ComputerVision', 'ContentModerator', 'CustomSpeech',
32
33
  # 'Emotion', 'Face', 'LUIS', 'Recommendations', 'SpeakerRecognition', 'Speech',
33
34
  # 'SpeechTranslation', 'TextAnalytics', 'TextTranslation', 'WebLM'
34
35
  # @param type [String] The Type of the resource.
@@ -37,8 +38,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
37
38
  #
38
39
  # @return [CheckSkuAvailabilityResultList] operation results.
39
40
  #
40
- def list(location, skus, kind, type, custom_headers = nil)
41
- response = list_async(location, skus, kind, type, custom_headers).value!
41
+ def list(location, skus, kind, type, custom_headers:nil)
42
+ response = list_async(location, skus, kind, type, custom_headers:custom_headers).value!
42
43
  response.body unless response.nil?
43
44
  end
44
45
 
@@ -48,8 +49,9 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
48
49
  # @param location [String] Resource location.
49
50
  # @param skus [Array<SkuName>] The SKU of the resource.
50
51
  # @param kind [Kind] The Kind of the resource. Possible values include:
51
- # 'Academic', 'Bing.Autosuggest', 'Bing.Search', 'Bing.Speech',
52
- # 'Bing.SpellCheck', 'ComputerVision', 'ContentModerator', 'CustomSpeech',
52
+ # 'Academic', 'Bing.Autosuggest', 'Bing.Autosuggest.v7', 'Bing.CustomSearch',
53
+ # 'Bing.Search', 'Bing.Search.v7', 'Bing.Speech', 'Bing.SpellCheck',
54
+ # 'Bing.SpellCheck.v7', 'ComputerVision', 'ContentModerator', 'CustomSpeech',
53
55
  # 'Emotion', 'Face', 'LUIS', 'Recommendations', 'SpeakerRecognition', 'Speech',
54
56
  # 'SpeechTranslation', 'TextAnalytics', 'TextTranslation', 'WebLM'
55
57
  # @param type [String] The Type of the resource.
@@ -58,8 +60,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
58
60
  #
59
61
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
60
62
  #
61
- def list_with_http_info(location, skus, kind, type, custom_headers = nil)
62
- list_async(location, skus, kind, type, custom_headers).value!
63
+ def list_with_http_info(location, skus, kind, type, custom_headers:nil)
64
+ list_async(location, skus, kind, type, custom_headers:custom_headers).value!
63
65
  end
64
66
 
65
67
  #
@@ -68,8 +70,9 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
68
70
  # @param location [String] Resource location.
69
71
  # @param skus [Array<SkuName>] The SKU of the resource.
70
72
  # @param kind [Kind] The Kind of the resource. Possible values include:
71
- # 'Academic', 'Bing.Autosuggest', 'Bing.Search', 'Bing.Speech',
72
- # 'Bing.SpellCheck', 'ComputerVision', 'ContentModerator', 'CustomSpeech',
73
+ # 'Academic', 'Bing.Autosuggest', 'Bing.Autosuggest.v7', 'Bing.CustomSearch',
74
+ # 'Bing.Search', 'Bing.Search.v7', 'Bing.Speech', 'Bing.SpellCheck',
75
+ # 'Bing.SpellCheck.v7', 'ComputerVision', 'ContentModerator', 'CustomSpeech',
73
76
  # 'Emotion', 'Face', 'LUIS', 'Recommendations', 'SpeakerRecognition', 'Speech',
74
77
  # 'SpeechTranslation', 'TextAnalytics', 'TextTranslation', 'WebLM'
75
78
  # @param type [String] The Type of the resource.
@@ -78,7 +81,7 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
78
81
  #
79
82
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
80
83
  #
81
- def list_async(location, skus, kind, type, custom_headers = nil)
84
+ def list_async(location, skus, kind, type, custom_headers:nil)
82
85
  fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
83
86
  fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
84
87
  fail ArgumentError, 'location is nil' if location.nil?
@@ -94,13 +97,12 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
94
97
  end
95
98
 
96
99
  request_headers = {}
100
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
97
101
 
98
102
  # Set Headers
99
103
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
100
104
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
101
105
 
102
- request_headers['Content-Type'] = 'application/json; charset=utf-8'
103
-
104
106
  # Serialize Request
105
107
  request_mapper = Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityParameter.mapper()
106
108
  request_content = @client.serialize(request_mapper, parameters)
@@ -113,6 +113,9 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
113
113
  fail ArgumentError, 'path is nil' if path.nil?
114
114
 
115
115
  request_url = options[:base_url] || @base_url
116
+ if(!options[:headers].nil? && !options[:headers]['Content-Type'].nil?)
117
+ @request_headers['Content-Type'] = options[:headers]['Content-Type']
118
+ end
116
119
 
117
120
  request_headers = @request_headers
118
121
  request_headers.merge!({'accept-language' => @accept_language}) unless @accept_language.nil?
@@ -129,7 +132,7 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
129
132
  #
130
133
  def add_telemetry
131
134
  sdk_information = 'azure_mgmt_cognitive_services'
132
- sdk_information = "#{sdk_information}/0.15.2"
135
+ sdk_information = "#{sdk_information}/0.16.0"
133
136
  add_user_agent_information(sdk_information)
134
137
  end
135
138
  end
@@ -16,11 +16,12 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
16
16
  attr_accessor :skus
17
17
 
18
18
  # @return [Kind] The Kind of the resource. Possible values include:
19
- # 'Academic', 'Bing.Autosuggest', 'Bing.Search', 'Bing.Speech',
20
- # 'Bing.SpellCheck', 'ComputerVision', 'ContentModerator',
21
- # 'CustomSpeech', 'Emotion', 'Face', 'LUIS', 'Recommendations',
22
- # 'SpeakerRecognition', 'Speech', 'SpeechTranslation', 'TextAnalytics',
23
- # 'TextTranslation', 'WebLM'
19
+ # 'Academic', 'Bing.Autosuggest', 'Bing.Autosuggest.v7',
20
+ # 'Bing.CustomSearch', 'Bing.Search', 'Bing.Search.v7', 'Bing.Speech',
21
+ # 'Bing.SpellCheck', 'Bing.SpellCheck.v7', 'ComputerVision',
22
+ # 'ContentModerator', 'CustomSpeech', 'Emotion', 'Face', 'LUIS',
23
+ # 'Recommendations', 'SpeakerRecognition', 'Speech', 'SpeechTranslation',
24
+ # 'TextAnalytics', 'TextTranslation', 'WebLM'
24
25
  attr_accessor :kind
25
26
 
26
27
  # @return [String] The Type of the resource.
@@ -13,11 +13,12 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
13
13
  include MsRestAzure
14
14
 
15
15
  # @return [Kind] The Kind of the resource. Possible values include:
16
- # 'Academic', 'Bing.Autosuggest', 'Bing.Search', 'Bing.Speech',
17
- # 'Bing.SpellCheck', 'ComputerVision', 'ContentModerator',
18
- # 'CustomSpeech', 'Emotion', 'Face', 'LUIS', 'Recommendations',
19
- # 'SpeakerRecognition', 'Speech', 'SpeechTranslation', 'TextAnalytics',
20
- # 'TextTranslation', 'WebLM'
16
+ # 'Academic', 'Bing.Autosuggest', 'Bing.Autosuggest.v7',
17
+ # 'Bing.CustomSearch', 'Bing.Search', 'Bing.Search.v7', 'Bing.Speech',
18
+ # 'Bing.SpellCheck', 'Bing.SpellCheck.v7', 'ComputerVision',
19
+ # 'ContentModerator', 'CustomSpeech', 'Emotion', 'Face', 'LUIS',
20
+ # 'Recommendations', 'SpeakerRecognition', 'Speech', 'SpeechTranslation',
21
+ # 'TextAnalytics', 'TextTranslation', 'WebLM'
21
22
  attr_accessor :kind
22
23
 
23
24
  # @return [String] The Type of the resource.
@@ -30,7 +30,7 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
30
30
 
31
31
  # @return [ProvisioningState] Gets the status of the cognitive services
32
32
  # account at the time the operation was called. Possible values include:
33
- # 'Creating', 'ResolvingDNS', 'Succeeded', 'Failed'
33
+ # 'Creating', 'ResolvingDNS', 'Moving', 'Deleting', 'Succeeded', 'Failed'
34
34
  attr_accessor :provisioning_state
35
35
 
36
36
  # @return [String] Endpoint of the created account.
@@ -114,8 +114,7 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
114
114
  read_only: true,
115
115
  serialized_name: 'properties.provisioningState',
116
116
  type: {
117
- name: 'Enum',
118
- module: 'ProvisioningState'
117
+ name: 'String'
119
118
  }
120
119
  },
121
120
  endpoint: {
@@ -16,8 +16,10 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
16
16
  attr_accessor :sku
17
17
 
18
18
  # @return [Kind] Required. Gets or sets the Kind of the resource.
19
- # Possible values include: 'Academic', 'Bing.Autosuggest', 'Bing.Search',
20
- # 'Bing.Speech', 'Bing.SpellCheck', 'ComputerVision', 'ContentModerator',
19
+ # Possible values include: 'Academic', 'Bing.Autosuggest',
20
+ # 'Bing.Autosuggest.v7', 'Bing.CustomSearch', 'Bing.Search',
21
+ # 'Bing.Search.v7', 'Bing.Speech', 'Bing.SpellCheck',
22
+ # 'Bing.SpellCheck.v7', 'ComputerVision', 'ContentModerator',
21
23
  # 'CustomSpeech', 'Emotion', 'Face', 'LUIS', 'Recommendations',
22
24
  # 'SpeakerRecognition', 'Speech', 'SpeechTranslation', 'TextAnalytics',
23
25
  # 'TextTranslation', 'WebLM'
@@ -11,9 +11,13 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
11
11
  module Kind
12
12
  Academic = "Academic"
13
13
  BingAutosuggest = "Bing.Autosuggest"
14
+ BingAutosuggestv7 = "Bing.Autosuggest.v7"
15
+ BingCustomSearch = "Bing.CustomSearch"
14
16
  BingSearch = "Bing.Search"
17
+ BingSearchv7 = "Bing.Search.v7"
15
18
  BingSpeech = "Bing.Speech"
16
19
  BingSpellCheck = "Bing.SpellCheck"
20
+ BingSpellCheckv7 = "Bing.SpellCheck.v7"
17
21
  ComputerVision = "ComputerVision"
18
22
  ContentModerator = "ContentModerator"
19
23
  CustomSpeech = "CustomSpeech"
@@ -11,6 +11,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
11
11
  module ProvisioningState
12
12
  Creating = "Creating"
13
13
  ResolvingDNS = "ResolvingDNS"
14
+ Moving = "Moving"
15
+ Deleting = "Deleting"
14
16
  Succeeded = "Succeeded"
15
17
  Failed = "Failed"
16
18
  end
@@ -29,8 +29,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
29
29
  #
30
30
  # @return [Array<OperationEntity>] operation results.
31
31
  #
32
- def list(custom_headers = nil)
33
- first_page = list_as_lazy(custom_headers)
32
+ def list(custom_headers:nil)
33
+ first_page = list_as_lazy(custom_headers:custom_headers)
34
34
  first_page.get_all_items
35
35
  end
36
36
 
@@ -42,8 +42,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
42
42
  #
43
43
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
44
44
  #
45
- def list_with_http_info(custom_headers = nil)
46
- list_async(custom_headers).value!
45
+ def list_with_http_info(custom_headers:nil)
46
+ list_async(custom_headers:custom_headers).value!
47
47
  end
48
48
 
49
49
  #
@@ -54,11 +54,12 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
54
54
  #
55
55
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
56
56
  #
57
- def list_async(custom_headers = nil)
57
+ def list_async(custom_headers:nil)
58
58
  fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
59
59
 
60
60
 
61
61
  request_headers = {}
62
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
62
63
 
63
64
  # Set Headers
64
65
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -112,8 +113,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
112
113
  #
113
114
  # @return [OperationEntityListResult] operation results.
114
115
  #
115
- def list_next(next_page_link, custom_headers = nil)
116
- response = list_next_async(next_page_link, custom_headers).value!
116
+ def list_next(next_page_link, custom_headers:nil)
117
+ response = list_next_async(next_page_link, custom_headers:custom_headers).value!
117
118
  response.body unless response.nil?
118
119
  end
119
120
 
@@ -127,8 +128,8 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
127
128
  #
128
129
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
129
130
  #
130
- def list_next_with_http_info(next_page_link, custom_headers = nil)
131
- list_next_async(next_page_link, custom_headers).value!
131
+ def list_next_with_http_info(next_page_link, custom_headers:nil)
132
+ list_next_async(next_page_link, custom_headers:custom_headers).value!
132
133
  end
133
134
 
134
135
  #
@@ -141,11 +142,12 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
141
142
  #
142
143
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
143
144
  #
144
- def list_next_async(next_page_link, custom_headers = nil)
145
+ def list_next_async(next_page_link, custom_headers:nil)
145
146
  fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
146
147
 
147
148
 
148
149
  request_headers = {}
150
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
149
151
 
150
152
  # Set Headers
151
153
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -198,12 +200,12 @@ module Azure::CognitiveServices::Mgmt::V2017_04_18
198
200
  # @return [OperationEntityListResult] which provide lazy access to pages of the
199
201
  # response.
200
202
  #
201
- def list_as_lazy(custom_headers = nil)
202
- response = list_async(custom_headers).value!
203
+ def list_as_lazy(custom_headers:nil)
204
+ response = list_async(custom_headers:custom_headers).value!
203
205
  unless response.nil?
204
206
  page = response.body
205
207
  page.next_method = Proc.new do |next_page_link|
206
- list_next_async(next_page_link, custom_headers)
208
+ list_next_async(next_page_link, custom_headers:custom_headers)
207
209
  end
208
210
  page
209
211
  end
@@ -2,5 +2,6 @@
2
2
  # Copyright (c) Microsoft Corporation. All rights reserved.
3
3
  # Licensed under the MIT License. See License.txt in the project root for license information.
4
4
 
5
+ require '2016-02-01-preview/generated/azure_mgmt_cognitive_services'
5
6
  require '2017-04-18/generated/azure_mgmt_cognitive_services'
6
7
  require 'profiles/latest/cognitiveservices_latest_profile_client'
@@ -5,17 +5,36 @@
5
5
  require 'profiles/latest/cognitiveservices_module_definition'
6
6
  require 'profiles/latest/modules/cognitiveservices_profile_module'
7
7
 
8
- module Azure::CognitiveServices::Profiles::Latest::Mgmt
9
- #
10
- # Client class for the Latest profile SDK.
11
- #
12
- class Client < CognitiveServicesClass
13
- include MsRestAzure::Common::Configurable
8
+ module Azure::CognitiveServices::Profiles::Latest
9
+ module Mgmt
10
+ #
11
+ # Client class for the Latest profile SDK.
12
+ #
13
+ class Client < CognitiveServicesManagementClass
14
+ include MsRestAzure::Common::Configurable
14
15
 
16
+ #
17
+ # Initializes a new instance of the Client class.
18
+ # @param options [Hash] hash of client options.
19
+ # options = {
20
+ # tenant_id: 'YOUR TENANT ID',
21
+ # client_id: 'YOUR CLIENT ID',
22
+ # client_secret: 'YOUR CLIENT SECRET',
23
+ # subscription_id: 'YOUR SUBSCRIPTION ID',
24
+ # credentials: credentials,
25
+ # active_directory_settings: active_directory_settings,
26
+ # base_url: 'YOUR BASE URL',
27
+ # options: options
28
+ # }
29
+ # 'credentials' are optional and if not passed in the hash, will be obtained
30
+ # from MsRest::TokenCredentials using MsRestAzure::ApplicationTokenProvider.
31
+ #
32
+ # Also, base_url, active_directory_settings & options are optional.
33
+ #
34
+ def initialize(options = {})
35
+ super(options)
36
+ end
15
37
 
16
- def initialize(options = {})
17
- super(options)
18
38
  end
19
-
20
39
  end
21
40
  end
@@ -6,4 +6,3 @@ module Azure end
6
6
  module Azure::CognitiveServices end
7
7
  module Azure::CognitiveServices::Profiles end
8
8
  module Azure::CognitiveServices::Profiles::Latest end
9
- module Azure::CognitiveServices::Profiles::Latest::Mgmt end
@@ -4,7 +4,8 @@
4
4
 
5
5
  require 'azure_mgmt_cognitive_services'
6
6
 
7
- module Azure::CognitiveServices::Profiles::Latest::Mgmt
7
+ module Azure::CognitiveServices::Profiles::Latest
8
+ module Mgmt
8
9
  Accounts = Azure::CognitiveServices::Mgmt::V2017_04_18::Accounts
9
10
  Operations = Azure::CognitiveServices::Mgmt::V2017_04_18::Operations
10
11
  CheckSkuAvailability = Azure::CognitiveServices::Mgmt::V2017_04_18::CheckSkuAvailability
@@ -35,9 +36,9 @@ module Azure::CognitiveServices::Profiles::Latest::Mgmt
35
36
  end
36
37
 
37
38
  #
38
- # CognitiveServices
39
+ # CognitiveServicesManagementClass
39
40
  #
40
- class CognitiveServicesClass
41
+ class CognitiveServicesManagementClass
41
42
  attr_reader :accounts, :operations, :check_sku_availability, :configurable, :base_url, :options, :model_classes
42
43
 
43
44
  def initialize(options = {})
@@ -49,86 +50,104 @@ module Azure::CognitiveServices::Profiles::Latest::Mgmt
49
50
 
50
51
  reset!(options)
51
52
 
52
- @configurable, @base_url, @options = self, nil, nil
53
+ @configurable = self
54
+ @base_url = options[:base_url].nil? ? nil:options[:base_url]
55
+ @options = options[:options].nil? ? nil:options[:options]
53
56
 
54
- client_0 = Azure::CognitiveServices::Mgmt::V2017_04_18::CognitiveServicesManagementClient.new(configurable.credentials, base_url, options)
55
- if(client_0.respond_to?(:subscription_id))
56
- client_0.subscription_id = configurable.subscription_id
57
- end
58
- @accounts = client_0.accounts
59
- @operations = client_0.operations
60
- @check_sku_availability = client_0.check_sku_availability
57
+ @client_0 = Azure::CognitiveServices::Mgmt::V2017_04_18::CognitiveServicesManagementClient.new(configurable.credentials, base_url, options)
58
+ if(@client_0.respond_to?(:subscription_id))
59
+ @client_0.subscription_id = configurable.subscription_id
60
+ end
61
+ add_telemetry(@client_0)
62
+ @accounts = @client_0.accounts
63
+ @operations = @client_0.operations
64
+ @check_sku_availability = @client_0.check_sku_availability
61
65
 
62
66
  @model_classes = ModelClasses.new
63
67
  end
64
68
 
65
- class ModelClasses
66
- def cognitive_services_account_enumerate_skus_result
67
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountEnumerateSkusResult
68
- end
69
- def error_body
70
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::ErrorBody
71
- end
72
- def cognitive_services_account_create_parameters
73
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountCreateParameters
74
- end
75
- def error
76
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::Error
77
- end
78
- def cognitive_services_account
79
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccount
80
- end
81
- def operation_display_info
82
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::OperationDisplayInfo
83
- end
84
- def cognitive_services_account_keys
85
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountKeys
86
- end
87
- def operation_entity
88
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::OperationEntity
89
- end
90
- def cognitive_services_resource_and_sku
91
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesResourceAndSku
92
- end
93
- def operation_entity_list_result
94
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::OperationEntityListResult
95
- end
96
- def cognitive_services_account_update_parameters
97
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountUpdateParameters
98
- end
99
- def check_sku_availability_parameter
100
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityParameter
101
- end
102
- def regenerate_key_parameters
103
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::RegenerateKeyParameters
104
- end
105
- def check_sku_availability_result
106
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityResult
107
- end
108
- def cognitive_services_account_list_result
109
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountListResult
110
- end
111
- def check_sku_availability_result_list
112
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityResultList
113
- end
114
- def sku
115
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::Sku
116
- end
117
- def sku_name
118
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::SkuName
119
- end
120
- def sku_tier
121
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::SkuTier
122
- end
123
- def kind
124
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::Kind
125
- end
126
- def provisioning_state
127
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::ProvisioningState
128
- end
129
- def key_name
130
- Azure::CognitiveServices::Mgmt::V2017_04_18::Models::KeyName
69
+ def add_telemetry(client)
70
+ profile_information = 'Profiles/Latest/CognitiveServices/Mgmt'
71
+ client.add_user_agent_information(profile_information)
72
+ end
73
+
74
+ def method_missing(method, *args)
75
+ if @client_0.respond_to?method
76
+ @client_0.send(method, *args)
77
+ else
78
+ super
131
79
  end
132
80
  end
81
+
82
+ end
83
+
84
+ class ModelClasses
85
+ def cognitive_services_account_enumerate_skus_result
86
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountEnumerateSkusResult
87
+ end
88
+ def error_body
89
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::ErrorBody
90
+ end
91
+ def cognitive_services_account_create_parameters
92
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountCreateParameters
93
+ end
94
+ def error
95
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::Error
96
+ end
97
+ def cognitive_services_account
98
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccount
99
+ end
100
+ def operation_display_info
101
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::OperationDisplayInfo
102
+ end
103
+ def cognitive_services_account_keys
104
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountKeys
105
+ end
106
+ def operation_entity
107
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::OperationEntity
108
+ end
109
+ def cognitive_services_resource_and_sku
110
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesResourceAndSku
111
+ end
112
+ def operation_entity_list_result
113
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::OperationEntityListResult
114
+ end
115
+ def cognitive_services_account_update_parameters
116
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountUpdateParameters
117
+ end
118
+ def check_sku_availability_parameter
119
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityParameter
120
+ end
121
+ def regenerate_key_parameters
122
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::RegenerateKeyParameters
123
+ end
124
+ def check_sku_availability_result
125
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityResult
126
+ end
127
+ def cognitive_services_account_list_result
128
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CognitiveServicesAccountListResult
129
+ end
130
+ def check_sku_availability_result_list
131
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::CheckSkuAvailabilityResultList
132
+ end
133
+ def sku
134
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::Sku
135
+ end
136
+ def sku_name
137
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::SkuName
138
+ end
139
+ def sku_tier
140
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::SkuTier
141
+ end
142
+ def kind
143
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::Kind
144
+ end
145
+ def provisioning_state
146
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::ProvisioningState
147
+ end
148
+ def key_name
149
+ Azure::CognitiveServices::Mgmt::V2017_04_18::Models::KeyName
150
+ end
133
151
  end
152
+ end
134
153
  end