Skip to content

Commit

Permalink
CodeGen from PR 12832 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
add python track2 config for privatedns (Azure#12832)
  • Loading branch information
SDKAuto committed Feb 8, 2021
1 parent 1cdf789 commit 13a5a02
Show file tree
Hide file tree
Showing 15 changed files with 131 additions and 54 deletions.
2 changes: 1 addition & 1 deletion sdk/privatedns/arm-privatedns/LICENSE.txt
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
9 changes: 4 additions & 5 deletions sdk/privatedns/arm-privatedns/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ npm install @azure/arm-privatedns

### How to use

#### nodejs - Authentication, client creation and get privateZones as an example written in TypeScript.
#### nodejs - client creation and get privateZones as an example written in TypeScript.

##### Install @azure/ms-rest-nodeauth

Expand All @@ -26,11 +26,10 @@ npm install @azure/ms-rest-nodeauth@"^3.0.0"

##### Sample code

While the below sample uses the interactive login, other authentication options can be found in the [README.md file of @azure/ms-rest-nodeauth](https://www.npmjs.com/package/@azure/ms-rest-nodeauth) package
```typescript
import * as msRest from "@azure/ms-rest-js";
import * as msRestAzure from "@azure/ms-rest-azure-js";
import * as msRestNodeAuth from "@azure/ms-rest-nodeauth";
import { PrivateDnsManagementClient, PrivateDnsManagementModels, PrivateDnsManagementMappers } from "@azure/arm-privatedns";
const msRestNodeAuth = require("@azure/ms-rest-nodeauth");
const { PrivateDnsManagementClient } = require("@azure/arm-privatedns");
const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"];

msRestNodeAuth.interactiveLogin().then((creds) => {
Expand Down
4 changes: 2 additions & 2 deletions sdk/privatedns/arm-privatedns/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ const config = {
"@azure/ms-rest-azure-js": "msRestAzure"
},
banner: `/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
67 changes: 65 additions & 2 deletions sdk/privatedns/arm-privatedns/src/models/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down Expand Up @@ -429,6 +429,26 @@ export interface PrivateZonesBeginDeleteMethodOptionalParams extends msRest.Requ
ifMatch?: string;
}

/**
* Optional Parameters.
*/
export interface PrivateZonesListNextOptionalParams extends msRest.RequestOptionsBase {
/**
* The maximum number of Private DNS zones to return. If not specified, returns up to 100 zones.
*/
top?: number;
}

/**
* Optional Parameters.
*/
export interface PrivateZonesListByResourceGroupNextOptionalParams extends msRest.RequestOptionsBase {
/**
* The maximum number of record sets to return. If not specified, returns up to 100 record sets.
*/
top?: number;
}

/**
* Optional Parameters.
*/
Expand Down Expand Up @@ -522,6 +542,17 @@ export interface VirtualNetworkLinksBeginDeleteMethodOptionalParams extends msRe
ifMatch?: string;
}

/**
* Optional Parameters.
*/
export interface VirtualNetworkLinksListNextOptionalParams extends msRest.RequestOptionsBase {
/**
* The maximum number of virtual network links to return. If not specified, returns up to 100
* virtual network links.
*/
top?: number;
}

/**
* Optional Parameters.
*/
Expand Down Expand Up @@ -592,6 +623,38 @@ export interface RecordSetsListOptionalParams extends msRest.RequestOptionsBase
recordsetnamesuffix?: string;
}

/**
* Optional Parameters.
*/
export interface RecordSetsListByTypeNextOptionalParams extends msRest.RequestOptionsBase {
/**
* The maximum number of record sets to return. If not specified, returns up to 100 record sets.
*/
top?: number;
/**
* The suffix label of the record set name to be used to filter the record set enumeration. If
* this parameter is specified, the returned enumeration will only contain records that end with
* ".<recordsetnamesuffix>".
*/
recordsetnamesuffix?: string;
}

/**
* Optional Parameters.
*/
export interface RecordSetsListNextOptionalParams extends msRest.RequestOptionsBase {
/**
* The maximum number of record sets to return. If not specified, returns up to 100 record sets.
*/
top?: number;
/**
* The suffix label of the record set name to be used to filter the record set enumeration. If
* this parameter is specified, the returned enumeration will only contain records that end with
* ".<recordsetnamesuffix>".
*/
recordsetnamesuffix?: string;
}

/**
* An interface representing PrivateDnsManagementClientOptions.
*/
Expand Down
4 changes: 2 additions & 2 deletions sdk/privatedns/arm-privatedns/src/models/mappers.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
5 changes: 2 additions & 3 deletions sdk/privatedns/arm-privatedns/src/models/parameters.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
4 changes: 2 additions & 2 deletions sdk/privatedns/arm-privatedns/src/models/recordSetsMappers.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
Expand Down
5 changes: 2 additions & 3 deletions sdk/privatedns/arm-privatedns/src/operations/index.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down
25 changes: 16 additions & 9 deletions sdk/privatedns/arm-privatedns/src/operations/privateZones.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down Expand Up @@ -222,7 +221,7 @@ export class PrivateZones {
* @param [options] The optional parameters
* @returns Promise<Models.PrivateZonesListNextResponse>
*/
listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.PrivateZonesListNextResponse>;
listNext(nextPageLink: string, options?: Models.PrivateZonesListNextOptionalParams): Promise<Models.PrivateZonesListNextResponse>;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param callback The callback
Expand All @@ -233,8 +232,8 @@ export class PrivateZones {
* @param options The optional parameters
* @param callback The callback
*/
listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.PrivateZoneListResult>): void;
listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.PrivateZoneListResult>, callback?: msRest.ServiceCallback<Models.PrivateZoneListResult>): Promise<Models.PrivateZonesListNextResponse> {
listNext(nextPageLink: string, options: Models.PrivateZonesListNextOptionalParams, callback: msRest.ServiceCallback<Models.PrivateZoneListResult>): void;
listNext(nextPageLink: string, options?: Models.PrivateZonesListNextOptionalParams | msRest.ServiceCallback<Models.PrivateZoneListResult>, callback?: msRest.ServiceCallback<Models.PrivateZoneListResult>): Promise<Models.PrivateZonesListNextResponse> {
return this.client.sendOperationRequest(
{
nextPageLink,
Expand All @@ -250,7 +249,7 @@ export class PrivateZones {
* @param [options] The optional parameters
* @returns Promise<Models.PrivateZonesListByResourceGroupNextResponse>
*/
listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.PrivateZonesListByResourceGroupNextResponse>;
listByResourceGroupNext(nextPageLink: string, options?: Models.PrivateZonesListByResourceGroupNextOptionalParams): Promise<Models.PrivateZonesListByResourceGroupNextResponse>;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param callback The callback
Expand All @@ -261,8 +260,8 @@ export class PrivateZones {
* @param options The optional parameters
* @param callback The callback
*/
listByResourceGroupNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.PrivateZoneListResult>): void;
listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.PrivateZoneListResult>, callback?: msRest.ServiceCallback<Models.PrivateZoneListResult>): Promise<Models.PrivateZonesListByResourceGroupNextResponse> {
listByResourceGroupNext(nextPageLink: string, options: Models.PrivateZonesListByResourceGroupNextOptionalParams, callback: msRest.ServiceCallback<Models.PrivateZoneListResult>): void;
listByResourceGroupNext(nextPageLink: string, options?: Models.PrivateZonesListByResourceGroupNextOptionalParams | msRest.ServiceCallback<Models.PrivateZoneListResult>, callback?: msRest.ServiceCallback<Models.PrivateZoneListResult>): Promise<Models.PrivateZonesListByResourceGroupNextResponse> {
return this.client.sendOperationRequest(
{
nextPageLink,
Expand Down Expand Up @@ -454,6 +453,10 @@ const listNextOperationSpec: msRest.OperationSpec = {
urlParameters: [
Parameters.nextPageLink
],
queryParameters: [
Parameters.top,
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
Expand All @@ -475,6 +478,10 @@ const listByResourceGroupNextOperationSpec: msRest.OperationSpec = {
urlParameters: [
Parameters.nextPageLink
],
queryParameters: [
Parameters.top,
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
Expand Down
27 changes: 18 additions & 9 deletions sdk/privatedns/arm-privatedns/src/operations/recordSets.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down Expand Up @@ -289,7 +288,7 @@ export class RecordSets {
* @param [options] The optional parameters
* @returns Promise<Models.RecordSetsListByTypeNextResponse>
*/
listByTypeNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.RecordSetsListByTypeNextResponse>;
listByTypeNext(nextPageLink: string, options?: Models.RecordSetsListByTypeNextOptionalParams): Promise<Models.RecordSetsListByTypeNextResponse>;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param callback The callback
Expand All @@ -300,8 +299,8 @@ export class RecordSets {
* @param options The optional parameters
* @param callback The callback
*/
listByTypeNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.RecordSetListResult>): void;
listByTypeNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.RecordSetListResult>, callback?: msRest.ServiceCallback<Models.RecordSetListResult>): Promise<Models.RecordSetsListByTypeNextResponse> {
listByTypeNext(nextPageLink: string, options: Models.RecordSetsListByTypeNextOptionalParams, callback: msRest.ServiceCallback<Models.RecordSetListResult>): void;
listByTypeNext(nextPageLink: string, options?: Models.RecordSetsListByTypeNextOptionalParams | msRest.ServiceCallback<Models.RecordSetListResult>, callback?: msRest.ServiceCallback<Models.RecordSetListResult>): Promise<Models.RecordSetsListByTypeNextResponse> {
return this.client.sendOperationRequest(
{
nextPageLink,
Expand All @@ -317,7 +316,7 @@ export class RecordSets {
* @param [options] The optional parameters
* @returns Promise<Models.RecordSetsListNextResponse>
*/
listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.RecordSetsListNextResponse>;
listNext(nextPageLink: string, options?: Models.RecordSetsListNextOptionalParams): Promise<Models.RecordSetsListNextResponse>;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param callback The callback
Expand All @@ -328,8 +327,8 @@ export class RecordSets {
* @param options The optional parameters
* @param callback The callback
*/
listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.RecordSetListResult>): void;
listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.RecordSetListResult>, callback?: msRest.ServiceCallback<Models.RecordSetListResult>): Promise<Models.RecordSetsListNextResponse> {
listNext(nextPageLink: string, options: Models.RecordSetsListNextOptionalParams, callback: msRest.ServiceCallback<Models.RecordSetListResult>): void;
listNext(nextPageLink: string, options?: Models.RecordSetsListNextOptionalParams | msRest.ServiceCallback<Models.RecordSetListResult>, callback?: msRest.ServiceCallback<Models.RecordSetListResult>): Promise<Models.RecordSetsListNextResponse> {
return this.client.sendOperationRequest(
{
nextPageLink,
Expand Down Expand Up @@ -532,6 +531,11 @@ const listByTypeNextOperationSpec: msRest.OperationSpec = {
urlParameters: [
Parameters.nextPageLink
],
queryParameters: [
Parameters.top,
Parameters.recordsetnamesuffix,
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
Expand All @@ -553,6 +557,11 @@ const listNextOperationSpec: msRest.OperationSpec = {
urlParameters: [
Parameters.nextPageLink
],
queryParameters: [
Parameters.top,
Parameters.recordsetnamesuffix,
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down Expand Up @@ -210,7 +209,7 @@ export class VirtualNetworkLinks {
* @param [options] The optional parameters
* @returns Promise<Models.VirtualNetworkLinksListNextResponse>
*/
listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.VirtualNetworkLinksListNextResponse>;
listNext(nextPageLink: string, options?: Models.VirtualNetworkLinksListNextOptionalParams): Promise<Models.VirtualNetworkLinksListNextResponse>;
/**
* @param nextPageLink The NextLink from the previous successful call to List operation.
* @param callback The callback
Expand All @@ -221,8 +220,8 @@ export class VirtualNetworkLinks {
* @param options The optional parameters
* @param callback The callback
*/
listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.VirtualNetworkLinkListResult>): void;
listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.VirtualNetworkLinkListResult>, callback?: msRest.ServiceCallback<Models.VirtualNetworkLinkListResult>): Promise<Models.VirtualNetworkLinksListNextResponse> {
listNext(nextPageLink: string, options: Models.VirtualNetworkLinksListNextOptionalParams, callback: msRest.ServiceCallback<Models.VirtualNetworkLinkListResult>): void;
listNext(nextPageLink: string, options?: Models.VirtualNetworkLinksListNextOptionalParams | msRest.ServiceCallback<Models.VirtualNetworkLinkListResult>, callback?: msRest.ServiceCallback<Models.VirtualNetworkLinkListResult>): Promise<Models.VirtualNetworkLinksListNextResponse> {
return this.client.sendOperationRequest(
{
nextPageLink,
Expand Down Expand Up @@ -395,6 +394,10 @@ const listNextOperationSpec: msRest.OperationSpec = {
urlParameters: [
Parameters.nextPageLink
],
queryParameters: [
Parameters.top,
Parameters.apiVersion
],
headerParameters: [
Parameters.acceptLanguage
],
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
Expand Down

0 comments on commit 13a5a02

Please sign in to comment.