Skip to content

Commit 8a8330a

Browse files
authored
Generate SDK for CognitiveService via autorest.powershell (#22808)
* Generate SDK for CognitiveService via autorest.powershell * Generate SDK for CognitiveService via autorest.powershell * Generate SDK for CognitiveService via autorest.powershell * Generate SDK for CognitiveService via autorest.powershell * Generate SDK for CognitiveService via autorest.powershell * Skip SDK verify
1 parent 4e372e5 commit 8a8330a

File tree

148 files changed

+9941
-10358
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

148 files changed

+9941
-10358
lines changed

src/CognitiveServices/CognitiveServices.Management.Sdk/Generated/AccountsOperations.cs

Lines changed: 903 additions & 819 deletions
Large diffs are not rendered by default.

src/CognitiveServices/CognitiveServices.Management.Sdk/Generated/AccountsOperationsExtensions.cs

Lines changed: 630 additions & 704 deletions
Large diffs are not rendered by default.

src/CognitiveServices/CognitiveServices.Management.Sdk/Generated/CognitiveServicesManagementClient.cs

Lines changed: 228 additions & 266 deletions
Large diffs are not rendered by default.
Lines changed: 57 additions & 106 deletions
Original file line numberDiff line numberDiff line change
@@ -1,125 +1,76 @@
1-
// <auto-generated>
21
// Copyright (c) Microsoft Corporation. All rights reserved.
3-
// Licensed under the MIT License. See License.txt in the project root for
4-
// license information.
5-
//
2+
// Licensed under the MIT License. See License.txt in the project root for license information.
63
// Code generated by Microsoft (R) AutoRest Code Generator.
7-
// Changes may cause incorrect behavior and will be lost if the code is
8-
// regenerated.
9-
// </auto-generated>
10-
4+
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
115
namespace Microsoft.Azure.Management.CognitiveServices
126
{
13-
using Microsoft.Rest;
147
using Microsoft.Rest.Azure;
158
using Models;
16-
using System.Collections;
17-
using System.Collections.Generic;
18-
using System.Threading;
19-
using System.Threading.Tasks;
209

2110
/// <summary>
22-
/// Extension methods for CognitiveServicesManagementClient.
11+
/// Extension methods for CognitiveServicesManagementClient
2312
/// </summary>
2413
public static partial class CognitiveServicesManagementClientExtensions
2514
{
26-
/// <summary>
27-
/// Check available SKUs.
28-
/// </summary>
29-
/// <param name='operations'>
30-
/// The operations group for this extension method.
31-
/// </param>
32-
/// <param name='location'>
33-
/// Resource location.
34-
/// </param>
35-
/// <param name='skus'>
36-
/// The SKU of the resource.
37-
/// </param>
38-
/// <param name='kind'>
39-
/// The Kind of the resource.
40-
/// </param>
41-
/// <param name='type'>
42-
/// The Type of the resource.
43-
/// </param>
44-
public static SkuAvailabilityListResult CheckSkuAvailability(this ICognitiveServicesManagementClient operations, string location, IList<string> skus, string kind, string type)
45-
{
46-
return operations.CheckSkuAvailabilityAsync(location, skus, kind, type).GetAwaiter().GetResult();
47-
}
15+
/// <summary>
16+
/// Check available SKUs.
17+
/// </summary>
18+
/// <param name='operations'>
19+
/// The operations group for this extension method.
20+
/// </param>
21+
/// <param name='location'>
22+
/// Resource location.
23+
/// </param>
24+
public static SkuAvailabilityListResult CheckSkuAvailability(this ICognitiveServicesManagementClient operations, string location, System.Collections.Generic.IList<string> skus, string kind, string type)
25+
{
26+
return ((ICognitiveServicesManagementClient)operations).CheckSkuAvailabilityAsync(location, skus, kind, type).GetAwaiter().GetResult();
27+
}
4828

49-
/// <summary>
50-
/// Check available SKUs.
51-
/// </summary>
52-
/// <param name='operations'>
53-
/// The operations group for this extension method.
54-
/// </param>
55-
/// <param name='location'>
56-
/// Resource location.
57-
/// </param>
58-
/// <param name='skus'>
59-
/// The SKU of the resource.
60-
/// </param>
61-
/// <param name='kind'>
62-
/// The Kind of the resource.
63-
/// </param>
64-
/// <param name='type'>
65-
/// The Type of the resource.
66-
/// </param>
67-
/// <param name='cancellationToken'>
68-
/// The cancellation token.
69-
/// </param>
70-
public static async Task<SkuAvailabilityListResult> CheckSkuAvailabilityAsync(this ICognitiveServicesManagementClient operations, string location, IList<string> skus, string kind, string type, CancellationToken cancellationToken = default(CancellationToken))
29+
/// <summary>
30+
/// Check available SKUs.
31+
/// </summary>
32+
/// <param name='operations'>
33+
/// The operations group for this extension method.
34+
/// </param>
35+
/// <param name='location'>
36+
/// Resource location.
37+
/// </param>
38+
/// <param name='cancellationToken'>
39+
/// The cancellation token.
40+
/// </param>
41+
public static async System.Threading.Tasks.Task<SkuAvailabilityListResult> CheckSkuAvailabilityAsync(this ICognitiveServicesManagementClient operations, string location, System.Collections.Generic.IList<string> skus, string kind, string type, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
42+
{
43+
using (var _result = await operations.CheckSkuAvailabilityWithHttpMessagesAsync(location, skus, kind, type, null, cancellationToken).ConfigureAwait(false))
7144
{
72-
using (var _result = await operations.CheckSkuAvailabilityWithHttpMessagesAsync(location, skus, kind, type, null, cancellationToken).ConfigureAwait(false))
73-
{
74-
return _result.Body;
75-
}
45+
return _result.Body;
7646
}
47+
}
48+
/// <summary>
49+
/// Check whether a domain is available.
50+
/// </summary>
51+
/// <param name='operations'>
52+
/// The operations group for this extension method.
53+
/// </param>
54+
public static DomainAvailability CheckDomainAvailability(this ICognitiveServicesManagementClient operations, string subdomainName, string type, string kind = default(string))
55+
{
56+
return ((ICognitiveServicesManagementClient)operations).CheckDomainAvailabilityAsync(subdomainName, type, kind).GetAwaiter().GetResult();
57+
}
7758

78-
/// <summary>
79-
/// Check whether a domain is available.
80-
/// </summary>
81-
/// <param name='operations'>
82-
/// The operations group for this extension method.
83-
/// </param>
84-
/// <param name='subdomainName'>
85-
/// The subdomain name to use.
86-
/// </param>
87-
/// <param name='type'>
88-
/// The Type of the resource.
89-
/// </param>
90-
/// <param name='kind'>
91-
/// The Kind of the resource.
92-
/// </param>
93-
public static DomainAvailability CheckDomainAvailability(this ICognitiveServicesManagementClient operations, string subdomainName, string type, string kind = default(string))
59+
/// <summary>
60+
/// Check whether a domain is available.
61+
/// </summary>
62+
/// <param name='operations'>
63+
/// The operations group for this extension method.
64+
/// </param>
65+
/// <param name='cancellationToken'>
66+
/// The cancellation token.
67+
/// </param>
68+
public static async System.Threading.Tasks.Task<DomainAvailability> CheckDomainAvailabilityAsync(this ICognitiveServicesManagementClient operations, string subdomainName, string type, string kind = default(string), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
69+
{
70+
using (var _result = await operations.CheckDomainAvailabilityWithHttpMessagesAsync(subdomainName, type, kind, null, cancellationToken).ConfigureAwait(false))
9471
{
95-
return operations.CheckDomainAvailabilityAsync(subdomainName, type, kind).GetAwaiter().GetResult();
72+
return _result.Body;
9673
}
97-
98-
/// <summary>
99-
/// Check whether a domain is available.
100-
/// </summary>
101-
/// <param name='operations'>
102-
/// The operations group for this extension method.
103-
/// </param>
104-
/// <param name='subdomainName'>
105-
/// The subdomain name to use.
106-
/// </param>
107-
/// <param name='type'>
108-
/// The Type of the resource.
109-
/// </param>
110-
/// <param name='kind'>
111-
/// The Kind of the resource.
112-
/// </param>
113-
/// <param name='cancellationToken'>
114-
/// The cancellation token.
115-
/// </param>
116-
public static async Task<DomainAvailability> CheckDomainAvailabilityAsync(this ICognitiveServicesManagementClient operations, string subdomainName, string type, string kind = default(string), CancellationToken cancellationToken = default(CancellationToken))
117-
{
118-
using (var _result = await operations.CheckDomainAvailabilityWithHttpMessagesAsync(subdomainName, type, kind, null, cancellationToken).ConfigureAwait(false))
119-
{
120-
return _result.Body;
121-
}
122-
}
123-
74+
}
12475
}
12576
}

0 commit comments

Comments
 (0)