Skip to content

Commit

Permalink
CodeGen from PR 12554 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 6366874ff095d3fcbc9fa742584b9ff483bca3a7 into 53af7fc754f605aabc80a33cceb53b6b0c5da71b
  • Loading branch information
SDKAuto committed Apr 22, 2021
1 parent 9186f29 commit d6a6999
Show file tree
Hide file tree
Showing 61 changed files with 29,957 additions and 1,462 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2020 Microsoft
Copyright (c) 2021 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
import * as msRest from "@azure/ms-rest-js";
import * as Models from "./models";
import * as Mappers from "./models/mappers";
import * as Parameters from "./models/parameters";
import * as operations from "./operations";
import { AzureMachineLearningWorkspacesContext } from "./azureMachineLearningWorkspacesContext";

Expand All @@ -20,137 +19,74 @@ class AzureMachineLearningWorkspaces extends AzureMachineLearningWorkspacesConte
operations: operations.Operations;
workspaces: operations.Workspaces;
workspaceFeatures: operations.WorkspaceFeatures;
notebooks: operations.Notebooks;
usages: operations.Usages;
virtualMachineSizes: operations.VirtualMachineSizes;
quotas: operations.Quotas;
workspaceConnections: operations.WorkspaceConnections;
machineLearningCompute: operations.MachineLearningCompute;
workspace: operations.WorkspaceOperations;
privateEndpointConnections: operations.PrivateEndpointConnections;
privateLinkResources: operations.PrivateLinkResources;
machineLearningService: operations.MachineLearningService;
notebooks: operations.Notebooks;
storageAccount: operations.StorageAccount;
workspaceConnections: operations.WorkspaceConnections;
batchDeployments: operations.BatchDeployments;
batchEndpoints: operations.BatchEndpoints;
codeContainers: operations.CodeContainers;
codeVersions: operations.CodeVersions;
dataContainers: operations.DataContainers;
datastores: operations.Datastores;
dataVersions: operations.DataVersions;
environmentContainers: operations.EnvironmentContainers;
environmentSpecificationVersions: operations.EnvironmentSpecificationVersions;
jobs: operations.Jobs;
labelingJobs: operations.LabelingJobs;
modelContainers: operations.ModelContainers;
modelVersions: operations.ModelVersions;
onlineDeployments: operations.OnlineDeployments;
onlineEndpoints: operations.OnlineEndpoints;

/**
* Initializes a new instance of the AzureMachineLearningWorkspaces class.
* @param credentials Credentials needed for the client to connect to Azure.
* @param subscriptionId Azure subscription identifier.
* @param subscriptionId The ID of the target subscription.
* @param [options] The parameter options
*/
constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.AzureMachineLearningWorkspacesOptions) {
super(credentials, subscriptionId, options);
this.operations = new operations.Operations(this);
this.workspaces = new operations.Workspaces(this);
this.workspaceFeatures = new operations.WorkspaceFeatures(this);
this.notebooks = new operations.Notebooks(this);
this.usages = new operations.Usages(this);
this.virtualMachineSizes = new operations.VirtualMachineSizes(this);
this.quotas = new operations.Quotas(this);
this.workspaceConnections = new operations.WorkspaceConnections(this);
this.machineLearningCompute = new operations.MachineLearningCompute(this);
this.workspace = new operations.WorkspaceOperations(this);
this.privateEndpointConnections = new operations.PrivateEndpointConnections(this);
this.privateLinkResources = new operations.PrivateLinkResources(this);
}

/**
* Lists all skus with associated features
* @param [options] The optional parameters
* @returns Promise<Models.ListSkusResponse>
*/
listSkus(options?: msRest.RequestOptionsBase): Promise<Models.ListSkusResponse>;
/**
* @param callback The callback
*/
listSkus(callback: msRest.ServiceCallback<Models.SkuListResult>): void;
/**
* @param options The optional parameters
* @param callback The callback
*/
listSkus(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SkuListResult>): void;
listSkus(options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SkuListResult>, callback?: msRest.ServiceCallback<Models.SkuListResult>): Promise<Models.ListSkusResponse> {
return this.sendOperationRequest(
{
options
},
listSkusOperationSpec,
callback) as Promise<Models.ListSkusResponse>;
}

/**
* Lists all skus with associated features
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param [options] The optional parameters
* @returns Promise<Models.ListSkusNextResponse>
*/
listSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.ListSkusNextResponse>;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param callback The callback
*/
listSkusNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.SkuListResult>): void;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param options The optional parameters
* @param callback The callback
*/
listSkusNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.SkuListResult>): void;
listSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.SkuListResult>, callback?: msRest.ServiceCallback<Models.SkuListResult>): Promise<Models.ListSkusNextResponse> {
return this.sendOperationRequest(
{
nextPageLink,
options
},
listSkusNextOperationSpec,
callback) as Promise<Models.ListSkusNextResponse>;
this.machineLearningService = new operations.MachineLearningService(this);
this.notebooks = new operations.Notebooks(this);
this.storageAccount = new operations.StorageAccount(this);
this.workspaceConnections = new operations.WorkspaceConnections(this);
this.batchDeployments = new operations.BatchDeployments(this);
this.batchEndpoints = new operations.BatchEndpoints(this);
this.codeContainers = new operations.CodeContainers(this);
this.codeVersions = new operations.CodeVersions(this);
this.dataContainers = new operations.DataContainers(this);
this.datastores = new operations.Datastores(this);
this.dataVersions = new operations.DataVersions(this);
this.environmentContainers = new operations.EnvironmentContainers(this);
this.environmentSpecificationVersions = new operations.EnvironmentSpecificationVersions(this);
this.jobs = new operations.Jobs(this);
this.labelingJobs = new operations.LabelingJobs(this);
this.modelContainers = new operations.ModelContainers(this);
this.modelVersions = new operations.ModelVersions(this);
this.onlineDeployments = new operations.OnlineDeployments(this);
this.onlineEndpoints = new operations.OnlineEndpoints(this);
}
}

// Operation Specifications
const serializer = new msRest.Serializer(Mappers);
const listSkusOperationSpec: msRest.OperationSpec = {
httpMethod: "GET",
path: "subscriptions/{subscriptionId}/providers/Microsoft.MachineLearningServices/workspaces/skus",
urlParameters: [
Parameters.subscriptionId
],
queryParameters: [
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
responses: {
200: {
bodyMapper: Mappers.SkuListResult
},
default: {
bodyMapper: Mappers.MachineLearningServiceError
}
},
serializer
};

const listSkusNextOperationSpec: msRest.OperationSpec = {
httpMethod: "GET",
baseUrl: "https://management.azure.com",
path: "{nextLink}",
urlParameters: [
Parameters.nextPageLink
],
queryParameters: [
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
responses: {
200: {
bodyMapper: Mappers.SkuListResult
},
default: {
bodyMapper: Mappers.MachineLearningServiceError
}
},
serializer
};

export {
AzureMachineLearningWorkspaces,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ const packageVersion = "4.0.0";

export class AzureMachineLearningWorkspacesContext extends msRestAzure.AzureServiceClient {
credentials: msRest.ServiceClientCredentials;
subscriptionId: string;
apiVersion?: string;
subscriptionId: string;

/**
* Initializes a new instance of the AzureMachineLearningWorkspaces class.
* @param credentials Credentials needed for the client to connect to Azure.
* @param subscriptionId Azure subscription identifier.
* @param subscriptionId The ID of the target subscription.
* @param [options] The parameter options
*/
constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.AzureMachineLearningWorkspacesOptions) {
Expand All @@ -43,7 +43,7 @@ export class AzureMachineLearningWorkspacesContext extends msRestAzure.AzureServ

super(credentials, options);

this.apiVersion = '2020-08-01';
this.apiVersion = '2021-03-01-preview';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
Expand Down
Loading

0 comments on commit d6a6999

Please sign in to comment.