diff --git a/lib/services/cdnManagement/LICENSE.txt b/lib/services/cdnManagement/LICENSE.txt index 0313a903d7..5431ba98b9 100644 --- a/lib/services/cdnManagement/LICENSE.txt +++ b/lib/services/cdnManagement/LICENSE.txt @@ -1,21 +1,21 @@ -The MIT License (MIT) - -Copyright (c) 2017 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 -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file +The MIT License (MIT) + +Copyright (c) 2018 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 +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lib/services/cdnManagement/lib/cdnManagementClient.d.ts b/lib/services/cdnManagement/lib/cdnManagementClient.d.ts index 6a7da5b6c4..a5c4aa7181 100644 --- a/lib/services/cdnManagement/lib/cdnManagementClient.d.ts +++ b/lib/services/cdnManagement/lib/cdnManagementClient.d.ts @@ -23,6 +23,8 @@ export default class CdnManagementClient extends AzureServiceClient { * * @param {string} subscriptionId - Azure Subscription ID. * + * @param {string} resourceGroupName - Name of the Resource group within the Azure subscription. + * * @param {string} [baseUri] - The base URI of the service. * * @param {object} [options] - The parameter options @@ -41,7 +43,7 @@ export default class CdnManagementClient extends AzureServiceClient { * @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. * */ - constructor(credentials: ServiceClientCredentials, subscriptionId: string, baseUri?: string, options?: AzureServiceClientOptions); + constructor(credentials: ServiceClientCredentials, subscriptionId: string, resourceGroupName: string, baseUri?: string, options?: AzureServiceClientOptions); credentials: ServiceClientCredentials; @@ -49,6 +51,8 @@ export default class CdnManagementClient extends AzureServiceClient { apiVersion: string; + resourceGroupName: string; + acceptLanguage: string; longRunningOperationRetryTimeout: number; diff --git a/lib/services/cdnManagement/lib/cdnManagementClient.js b/lib/services/cdnManagement/lib/cdnManagementClient.js index 261989035a..d9e4d4c9c3 100644 --- a/lib/services/cdnManagement/lib/cdnManagementClient.js +++ b/lib/services/cdnManagement/lib/cdnManagementClient.js @@ -514,6 +514,7 @@ class CdnManagementClient extends ServiceClient { * Create a CdnManagementClient. * @param {credentials} credentials - Credentials needed for the client to connect to Azure. * @param {string} subscriptionId - Azure Subscription ID. + * @param {string} resourceGroupName - Name of the Resource group within the Azure subscription. * @param {string} [baseUri] - The base URI of the service. * @param {object} [options] - The parameter options * @param {Array} [options.filters] - Filters to be added to the request pipeline @@ -524,13 +525,16 @@ class CdnManagementClient extends ServiceClient { * @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. * @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. */ - constructor(credentials, subscriptionId, baseUri, options) { + constructor(credentials, subscriptionId, resourceGroupName, baseUri, options) { if (credentials === null || credentials === undefined) { throw new Error('\'credentials\' cannot be null.'); } if (subscriptionId === null || subscriptionId === undefined) { throw new Error('\'subscriptionId\' cannot be null.'); } + if (resourceGroupName === null || resourceGroupName === undefined) { + throw new Error('\'resourceGroupName\' cannot be null.'); + } if (!options) options = {}; @@ -546,6 +550,7 @@ class CdnManagementClient extends ServiceClient { } this.credentials = credentials; this.subscriptionId = subscriptionId; + this.resourceGroupName = resourceGroupName; let packageInfo = this.getPackageJsonInfo(__dirname); this.addUserAgentInfo(`${packageInfo.name}/${packageInfo.version}`); diff --git a/lib/services/cdnManagement/lib/models/endpoint.js b/lib/services/cdnManagement/lib/models/endpoint.js index 2c59e5a48f..01f68315f5 100644 --- a/lib/services/cdnManagement/lib/models/endpoint.js +++ b/lib/services/cdnManagement/lib/models/endpoint.js @@ -240,6 +240,7 @@ class Endpoint extends models['TrackedResource'] { }, origins: { required: true, + readOnly: true, serializedName: 'properties.origins', type: { name: 'Sequence', diff --git a/lib/services/cdnManagement/lib/models/geoFilter.js b/lib/services/cdnManagement/lib/models/geoFilter.js index c0c6221667..9d7b39499a 100644 --- a/lib/services/cdnManagement/lib/models/geoFilter.js +++ b/lib/services/cdnManagement/lib/models/geoFilter.js @@ -52,8 +52,7 @@ class GeoFilter { required: true, serializedName: 'action', type: { - name: 'Enum', - allowedValues: [ 'Block', 'Allow' ] + name: 'String' } }, countryCodes: { diff --git a/lib/services/cdnManagement/lib/models/index.d.ts b/lib/services/cdnManagement/lib/models/index.d.ts index daf4d5e20f..c35cabb4b7 100644 --- a/lib/services/cdnManagement/lib/models/index.d.ts +++ b/lib/services/cdnManagement/lib/models/index.d.ts @@ -213,7 +213,7 @@ export interface Endpoint extends TrackedResource { geoFilters?: GeoFilter[]; deliveryPolicy?: EndpointPropertiesUpdateParametersDeliveryPolicy; readonly hostName?: string; - origins: DeepCreatedOrigin[]; + readonly origins: DeepCreatedOrigin[]; readonly resourceState?: string; readonly provisioningState?: string; } diff --git a/lib/services/cdnManagement/lib/operations/customDomains.js b/lib/services/cdnManagement/lib/operations/customDomains.js index fa1ab32b00..27accd6932 100644 --- a/lib/services/cdnManagement/lib/operations/customDomains.js +++ b/lib/services/cdnManagement/lib/operations/customDomains.js @@ -17,9 +17,6 @@ const WebResource = msRest.WebResource; /** * Lists all of the existing custom domains within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -45,7 +42,7 @@ const WebResource = msRest.WebResource; * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listByEndpoint(resourceGroupName, profileName, endpointName, options, callback) { +function _listByEndpoint(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -57,21 +54,21 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -96,7 +93,7 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -187,9 +184,6 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, /** * Gets an exisitng custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -217,7 +211,7 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _get(resourceGroupName, profileName, endpointName, customDomainName, options, callback) { +function _get(profileName, endpointName, customDomainName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -229,21 +223,21 @@ function _get(resourceGroupName, profileName, endpointName, customDomainName, op } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -271,7 +265,7 @@ function _get(resourceGroupName, profileName, endpointName, customDomainName, op // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{customDomainName}', encodeURIComponent(customDomainName)); @@ -364,9 +358,6 @@ function _get(resourceGroupName, profileName, endpointName, customDomainName, op /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -397,7 +388,7 @@ function _get(resourceGroupName, profileName, endpointName, customDomainName, op * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _create(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, callback) { +function _create(profileName, endpointName, customDomainName, hostName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -410,7 +401,7 @@ function _create(resourceGroupName, profileName, endpointName, customDomainName, } // Send request - this.beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, (err, parsedResult, httpRequest, response) => { + this.beginCreate(profileName, endpointName, customDomainName, hostName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -453,9 +444,6 @@ function _create(resourceGroupName, profileName, endpointName, customDomainName, /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -483,7 +471,7 @@ function _create(resourceGroupName, profileName, endpointName, customDomainName, * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _deleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, callback) { +function _deleteMethod(profileName, endpointName, customDomainName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -496,7 +484,7 @@ function _deleteMethod(resourceGroupName, profileName, endpointName, customDomai } // Send request - this.beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, (err, parsedResult, httpRequest, response) => { + this.beginDeleteMethod(profileName, endpointName, customDomainName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -538,9 +526,6 @@ function _deleteMethod(resourceGroupName, profileName, endpointName, customDomai /** * Disable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -568,7 +553,7 @@ function _deleteMethod(resourceGroupName, profileName, endpointName, customDomai * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _disableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, callback) { +function _disableCustomHttps(profileName, endpointName, customDomainName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -580,21 +565,21 @@ function _disableCustomHttps(resourceGroupName, profileName, endpointName, custo } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -622,7 +607,7 @@ function _disableCustomHttps(resourceGroupName, profileName, endpointName, custo // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/disableCustomHttps'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{customDomainName}', encodeURIComponent(customDomainName)); @@ -714,9 +699,6 @@ function _disableCustomHttps(resourceGroupName, profileName, endpointName, custo /** * Enable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -744,7 +726,7 @@ function _disableCustomHttps(resourceGroupName, profileName, endpointName, custo * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _enableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, callback) { +function _enableCustomHttps(profileName, endpointName, customDomainName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -756,21 +738,21 @@ function _enableCustomHttps(resourceGroupName, profileName, endpointName, custom } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -798,7 +780,7 @@ function _enableCustomHttps(resourceGroupName, profileName, endpointName, custom // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/enableCustomHttps'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{customDomainName}', encodeURIComponent(customDomainName)); @@ -890,9 +872,6 @@ function _enableCustomHttps(resourceGroupName, profileName, endpointName, custom /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -923,7 +902,7 @@ function _enableCustomHttps(resourceGroupName, profileName, endpointName, custom * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, callback) { +function _beginCreate(profileName, endpointName, customDomainName, hostName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -935,21 +914,21 @@ function _beginCreate(resourceGroupName, profileName, endpointName, customDomain } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -985,7 +964,7 @@ function _beginCreate(resourceGroupName, profileName, endpointName, customDomain // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{customDomainName}', encodeURIComponent(customDomainName)); @@ -1125,9 +1104,6 @@ function _beginCreate(resourceGroupName, profileName, endpointName, customDomain /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1155,7 +1131,7 @@ function _beginCreate(resourceGroupName, profileName, endpointName, customDomain * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, callback) { +function _beginDeleteMethod(profileName, endpointName, customDomainName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1167,21 +1143,21 @@ function _beginDeleteMethod(resourceGroupName, profileName, endpointName, custom } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1209,7 +1185,7 @@ function _beginDeleteMethod(resourceGroupName, profileName, endpointName, custom // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{customDomainName}', encodeURIComponent(customDomainName)); @@ -1449,9 +1425,6 @@ class CustomDomains { /** * Lists all of the existing custom domains within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1469,11 +1442,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - listByEndpointWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + listByEndpointWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listByEndpoint(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._listByEndpoint(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1486,9 +1459,6 @@ class CustomDomains { /** * Lists all of the existing custom domains within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1523,7 +1493,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listByEndpoint(resourceGroupName, profileName, endpointName, options, optionalCallback) { + listByEndpoint(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1532,23 +1502,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listByEndpoint(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._listByEndpoint(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listByEndpoint(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._listByEndpoint(profileName, endpointName, options, optionalCallback); } } /** * Gets an exisitng custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1569,11 +1536,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - getWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, options) { + getWithHttpOperationResponse(profileName, endpointName, customDomainName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._get(profileName, endpointName, customDomainName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1586,9 +1553,6 @@ class CustomDomains { /** * Gets an exisitng custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1625,7 +1589,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback) { + get(profileName, endpointName, customDomainName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1634,23 +1598,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._get(profileName, endpointName, customDomainName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._get(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback); + return self._get(profileName, endpointName, customDomainName, options, optionalCallback); } } /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1674,11 +1635,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - createWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, hostName, options) { + createWithHttpOperationResponse(profileName, endpointName, customDomainName, hostName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._create(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { + self._create(profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1691,9 +1652,6 @@ class CustomDomains { /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1733,7 +1691,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, optionalCallback) { + create(profileName, endpointName, customDomainName, hostName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1742,23 +1700,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._create(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { + self._create(profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._create(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, optionalCallback); + return self._create(profileName, endpointName, customDomainName, hostName, options, optionalCallback); } } /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1779,11 +1734,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, options) { + deleteMethodWithHttpOperationResponse(profileName, endpointName, customDomainName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._deleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._deleteMethod(profileName, endpointName, customDomainName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1796,9 +1751,6 @@ class CustomDomains { /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1835,7 +1787,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback) { + deleteMethod(profileName, endpointName, customDomainName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1844,23 +1796,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._deleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._deleteMethod(profileName, endpointName, customDomainName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._deleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback); + return self._deleteMethod(profileName, endpointName, customDomainName, options, optionalCallback); } } /** * Disable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1881,11 +1830,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - disableCustomHttpsWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, options) { + disableCustomHttpsWithHttpOperationResponse(profileName, endpointName, customDomainName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._disableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._disableCustomHttps(profileName, endpointName, customDomainName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1898,9 +1847,6 @@ class CustomDomains { /** * Disable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1937,7 +1883,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - disableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback) { + disableCustomHttps(profileName, endpointName, customDomainName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1946,23 +1892,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._disableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._disableCustomHttps(profileName, endpointName, customDomainName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._disableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback); + return self._disableCustomHttps(profileName, endpointName, customDomainName, options, optionalCallback); } } /** * Enable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1983,11 +1926,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - enableCustomHttpsWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, options) { + enableCustomHttpsWithHttpOperationResponse(profileName, endpointName, customDomainName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._enableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._enableCustomHttps(profileName, endpointName, customDomainName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2000,9 +1943,6 @@ class CustomDomains { /** * Enable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2039,7 +1979,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - enableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback) { + enableCustomHttps(profileName, endpointName, customDomainName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2048,23 +1988,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._enableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._enableCustomHttps(profileName, endpointName, customDomainName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._enableCustomHttps(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback); + return self._enableCustomHttps(profileName, endpointName, customDomainName, options, optionalCallback); } } /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2088,11 +2025,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, hostName, options) { + beginCreateWithHttpOperationResponse(profileName, endpointName, customDomainName, hostName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { + self._beginCreate(profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2105,9 +2042,6 @@ class CustomDomains { /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2147,7 +2081,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, optionalCallback) { + beginCreate(profileName, endpointName, customDomainName, hostName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2156,23 +2090,20 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { + self._beginCreate(profileName, endpointName, customDomainName, hostName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options, optionalCallback); + return self._beginCreate(profileName, endpointName, customDomainName, hostName, options, optionalCallback); } } /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2193,11 +2124,11 @@ class CustomDomains { * * @reject {Error} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName, profileName, endpointName, customDomainName, options) { + beginDeleteMethodWithHttpOperationResponse(profileName, endpointName, customDomainName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._beginDeleteMethod(profileName, endpointName, customDomainName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2210,9 +2141,6 @@ class CustomDomains { /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2249,7 +2177,7 @@ class CustomDomains { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback) { + beginDeleteMethod(profileName, endpointName, customDomainName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2258,14 +2186,14 @@ class CustomDomains { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, (err, result, request, response) => { + self._beginDeleteMethod(profileName, endpointName, customDomainName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options, optionalCallback); + return self._beginDeleteMethod(profileName, endpointName, customDomainName, options, optionalCallback); } } diff --git a/lib/services/cdnManagement/lib/operations/endpoints.js b/lib/services/cdnManagement/lib/operations/endpoints.js index 2175eab4c6..36d106bd3e 100644 --- a/lib/services/cdnManagement/lib/operations/endpoints.js +++ b/lib/services/cdnManagement/lib/operations/endpoints.js @@ -17,9 +17,6 @@ const WebResource = msRest.WebResource; /** * Lists existing CDN endpoints. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -41,7 +38,7 @@ const WebResource = msRest.WebResource; * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listByProfile(resourceGroupName, profileName, options, callback) { +function _listByProfile(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -53,21 +50,21 @@ function _listByProfile(resourceGroupName, profileName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -89,7 +86,7 @@ function _listByProfile(resourceGroupName, profileName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -180,9 +177,6 @@ function _listByProfile(resourceGroupName, profileName, options, callback) { * Gets an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -207,7 +201,7 @@ function _listByProfile(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _get(resourceGroupName, profileName, endpointName, options, callback) { +function _get(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -219,21 +213,21 @@ function _get(resourceGroupName, profileName, endpointName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -258,7 +252,7 @@ function _get(resourceGroupName, profileName, endpointName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -351,9 +345,6 @@ function _get(resourceGroupName, profileName, endpointName, options, callback) { * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -417,9 +408,6 @@ function _get(resourceGroupName, profileName, endpointName, options, callback) { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -442,7 +430,7 @@ function _get(resourceGroupName, profileName, endpointName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _create(resourceGroupName, profileName, endpointName, endpoint, options, callback) { +function _create(profileName, endpointName, endpoint, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -455,7 +443,7 @@ function _create(resourceGroupName, profileName, endpointName, endpoint, options } // Send request - this.beginCreate(resourceGroupName, profileName, endpointName, endpoint, options, (err, parsedResult, httpRequest, response) => { + this.beginCreate(profileName, endpointName, endpoint, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -502,9 +490,6 @@ function _create(resourceGroupName, profileName, endpointName, endpoint, options * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -594,7 +579,7 @@ function _create(resourceGroupName, profileName, endpointName, endpoint, options * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _update(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, callback) { +function _update(profileName, endpointName, endpointUpdateProperties, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -607,7 +592,7 @@ function _update(resourceGroupName, profileName, endpointName, endpointUpdatePro } // Send request - this.beginUpdate(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, (err, parsedResult, httpRequest, response) => { + this.beginUpdate(profileName, endpointName, endpointUpdateProperties, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -651,9 +636,6 @@ function _update(resourceGroupName, profileName, endpointName, endpointUpdatePro * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -677,7 +659,7 @@ function _update(resourceGroupName, profileName, endpointName, endpointUpdatePro * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _deleteMethod(resourceGroupName, profileName, endpointName, options, callback) { +function _deleteMethod(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -690,7 +672,7 @@ function _deleteMethod(resourceGroupName, profileName, endpointName, options, ca } // Send request - this.beginDeleteMethod(resourceGroupName, profileName, endpointName, options, (err, parsedResult, httpRequest, response) => { + this.beginDeleteMethod(profileName, endpointName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -719,9 +701,6 @@ function _deleteMethod(resourceGroupName, profileName, endpointName, options, ca /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -746,7 +725,7 @@ function _deleteMethod(resourceGroupName, profileName, endpointName, options, ca * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _start(resourceGroupName, profileName, endpointName, options, callback) { +function _start(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -759,7 +738,7 @@ function _start(resourceGroupName, profileName, endpointName, options, callback) } // Send request - this.beginStart(resourceGroupName, profileName, endpointName, options, (err, parsedResult, httpRequest, response) => { + this.beginStart(profileName, endpointName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -802,9 +781,6 @@ function _start(resourceGroupName, profileName, endpointName, options, callback) /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -829,7 +805,7 @@ function _start(resourceGroupName, profileName, endpointName, options, callback) * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _stop(resourceGroupName, profileName, endpointName, options, callback) { +function _stop(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -842,7 +818,7 @@ function _stop(resourceGroupName, profileName, endpointName, options, callback) } // Send request - this.beginStop(resourceGroupName, profileName, endpointName, options, (err, parsedResult, httpRequest, response) => { + this.beginStop(profileName, endpointName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -885,9 +861,6 @@ function _stop(resourceGroupName, profileName, endpointName, options, callback) /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -914,7 +887,7 @@ function _stop(resourceGroupName, profileName, endpointName, options, callback) * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _purgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, callback) { +function _purgeContent(profileName, endpointName, contentPaths, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -927,7 +900,7 @@ function _purgeContent(resourceGroupName, profileName, endpointName, contentPath } // Send request - this.beginPurgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, parsedResult, httpRequest, response) => { + this.beginPurgeContent(profileName, endpointName, contentPaths, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -956,9 +929,6 @@ function _purgeContent(resourceGroupName, profileName, endpointName, contentPath /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -985,7 +955,7 @@ function _purgeContent(resourceGroupName, profileName, endpointName, contentPath * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _loadContent(resourceGroupName, profileName, endpointName, contentPaths, options, callback) { +function _loadContent(profileName, endpointName, contentPaths, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -998,7 +968,7 @@ function _loadContent(resourceGroupName, profileName, endpointName, contentPaths } // Send request - this.beginLoadContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, parsedResult, httpRequest, response) => { + this.beginLoadContent(profileName, endpointName, contentPaths, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -1027,9 +997,6 @@ function _loadContent(resourceGroupName, profileName, endpointName, contentPaths * Validates the custom domain mapping to ensure it maps to the correct CDN * endpoint in DNS. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1058,7 +1025,7 @@ function _loadContent(resourceGroupName, profileName, endpointName, contentPaths * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _validateCustomDomain(resourceGroupName, profileName, endpointName, hostName, options, callback) { +function _validateCustomDomain(profileName, endpointName, hostName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1070,21 +1037,21 @@ function _validateCustomDomain(resourceGroupName, profileName, endpointName, hos } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1117,7 +1084,7 @@ function _validateCustomDomain(resourceGroupName, profileName, endpointName, hos // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/validateCustomDomain'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -1223,9 +1190,6 @@ function _validateCustomDomain(resourceGroupName, profileName, endpointName, hos * Checks the quota and usage of geo filters and custom domains under the given * endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1251,7 +1215,7 @@ function _validateCustomDomain(resourceGroupName, profileName, endpointName, hos * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listResourceUsage(resourceGroupName, profileName, endpointName, options, callback) { +function _listResourceUsage(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1263,21 +1227,21 @@ function _listResourceUsage(resourceGroupName, profileName, endpointName, option } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1302,7 +1266,7 @@ function _listResourceUsage(resourceGroupName, profileName, endpointName, option // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/checkResourceUsage'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -1394,9 +1358,6 @@ function _listResourceUsage(resourceGroupName, profileName, endpointName, option * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1460,9 +1421,6 @@ function _listResourceUsage(resourceGroupName, profileName, endpointName, option * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -1485,7 +1443,7 @@ function _listResourceUsage(resourceGroupName, profileName, endpointName, option * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginCreate(resourceGroupName, profileName, endpointName, endpoint, options, callback) { +function _beginCreate(profileName, endpointName, endpoint, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1497,21 +1455,21 @@ function _beginCreate(resourceGroupName, profileName, endpointName, endpoint, op } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1539,7 +1497,7 @@ function _beginCreate(resourceGroupName, profileName, endpointName, endpoint, op // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -1682,9 +1640,6 @@ function _beginCreate(resourceGroupName, profileName, endpointName, endpoint, op * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1774,7 +1729,7 @@ function _beginCreate(resourceGroupName, profileName, endpointName, endpoint, op * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginUpdate(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, callback) { +function _beginUpdate(profileName, endpointName, endpointUpdateProperties, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1786,21 +1741,21 @@ function _beginUpdate(resourceGroupName, profileName, endpointName, endpointUpda } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1828,7 +1783,7 @@ function _beginUpdate(resourceGroupName, profileName, endpointName, endpointUpda // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -1951,9 +1906,6 @@ function _beginUpdate(resourceGroupName, profileName, endpointName, endpointUpda * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1977,7 +1929,7 @@ function _beginUpdate(resourceGroupName, profileName, endpointName, endpointUpda * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginDeleteMethod(resourceGroupName, profileName, endpointName, options, callback) { +function _beginDeleteMethod(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1989,21 +1941,21 @@ function _beginDeleteMethod(resourceGroupName, profileName, endpointName, option } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -2028,7 +1980,7 @@ function _beginDeleteMethod(resourceGroupName, profileName, endpointName, option // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -2102,9 +2054,6 @@ function _beginDeleteMethod(resourceGroupName, profileName, endpointName, option /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2129,7 +2078,7 @@ function _beginDeleteMethod(resourceGroupName, profileName, endpointName, option * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginStart(resourceGroupName, profileName, endpointName, options, callback) { +function _beginStart(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -2141,21 +2090,21 @@ function _beginStart(resourceGroupName, profileName, endpointName, options, call } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -2180,7 +2129,7 @@ function _beginStart(resourceGroupName, profileName, endpointName, options, call // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/start'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -2288,9 +2237,6 @@ function _beginStart(resourceGroupName, profileName, endpointName, options, call /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2315,7 +2261,7 @@ function _beginStart(resourceGroupName, profileName, endpointName, options, call * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginStop(resourceGroupName, profileName, endpointName, options, callback) { +function _beginStop(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -2327,21 +2273,21 @@ function _beginStop(resourceGroupName, profileName, endpointName, options, callb } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -2366,7 +2312,7 @@ function _beginStop(resourceGroupName, profileName, endpointName, options, callb // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/stop'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -2474,9 +2420,6 @@ function _beginStop(resourceGroupName, profileName, endpointName, options, callb /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2503,7 +2446,7 @@ function _beginStop(resourceGroupName, profileName, endpointName, options, callb * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginPurgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, callback) { +function _beginPurgeContent(profileName, endpointName, contentPaths, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -2515,21 +2458,21 @@ function _beginPurgeContent(resourceGroupName, profileName, endpointName, conten } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -2567,7 +2510,7 @@ function _beginPurgeContent(resourceGroupName, profileName, endpointName, conten // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/purge'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -2655,9 +2598,6 @@ function _beginPurgeContent(resourceGroupName, profileName, endpointName, conten /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2684,7 +2624,7 @@ function _beginPurgeContent(resourceGroupName, profileName, endpointName, conten * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginLoadContent(resourceGroupName, profileName, endpointName, contentPaths, options, callback) { +function _beginLoadContent(profileName, endpointName, contentPaths, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -2696,21 +2636,21 @@ function _beginLoadContent(resourceGroupName, profileName, endpointName, content } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -2748,7 +2688,7 @@ function _beginLoadContent(resourceGroupName, profileName, endpointName, content // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/load'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -3124,9 +3064,6 @@ class Endpoints { /** * Lists existing CDN endpoints. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3141,11 +3078,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - listByProfileWithHttpOperationResponse(resourceGroupName, profileName, options) { + listByProfileWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listByProfile(resourceGroupName, profileName, options, (err, result, request, response) => { + self._listByProfile(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3158,9 +3095,6 @@ class Endpoints { /** * Lists existing CDN endpoints. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3191,7 +3125,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listByProfile(resourceGroupName, profileName, options, optionalCallback) { + listByProfile(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3200,14 +3134,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listByProfile(resourceGroupName, profileName, options, (err, result, request, response) => { + self._listByProfile(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listByProfile(resourceGroupName, profileName, options, optionalCallback); + return self._listByProfile(profileName, options, optionalCallback); } } @@ -3215,9 +3149,6 @@ class Endpoints { * Gets an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3235,11 +3166,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - getWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + getWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._get(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3253,9 +3184,6 @@ class Endpoints { * Gets an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3289,7 +3217,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName, profileName, endpointName, options, optionalCallback) { + get(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3298,14 +3226,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._get(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._get(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._get(profileName, endpointName, options, optionalCallback); } } @@ -3313,9 +3241,6 @@ class Endpoints { * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3379,9 +3304,6 @@ class Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -3397,11 +3319,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - createWithHttpOperationResponse(resourceGroupName, profileName, endpointName, endpoint, options) { + createWithHttpOperationResponse(profileName, endpointName, endpoint, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._create(resourceGroupName, profileName, endpointName, endpoint, options, (err, result, request, response) => { + self._create(profileName, endpointName, endpoint, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3415,9 +3337,6 @@ class Endpoints { * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3481,9 +3400,6 @@ class Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -3515,7 +3431,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName, profileName, endpointName, endpoint, options, optionalCallback) { + create(profileName, endpointName, endpoint, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3524,14 +3440,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._create(resourceGroupName, profileName, endpointName, endpoint, options, (err, result, request, response) => { + self._create(profileName, endpointName, endpoint, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._create(resourceGroupName, profileName, endpointName, endpoint, options, optionalCallback); + return self._create(profileName, endpointName, endpoint, options, optionalCallback); } } @@ -3542,9 +3458,6 @@ class Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3627,11 +3540,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options) { + updateWithHttpOperationResponse(profileName, endpointName, endpointUpdateProperties, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._update(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { + self._update(profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3648,9 +3561,6 @@ class Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3749,7 +3659,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, optionalCallback) { + update(profileName, endpointName, endpointUpdateProperties, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3758,14 +3668,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._update(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { + self._update(profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._update(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, optionalCallback); + return self._update(profileName, endpointName, endpointUpdateProperties, options, optionalCallback); } } @@ -3773,9 +3683,6 @@ class Endpoints { * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3793,11 +3700,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + deleteMethodWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._deleteMethod(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._deleteMethod(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3811,9 +3718,6 @@ class Endpoints { * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3846,7 +3750,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName, profileName, endpointName, options, optionalCallback) { + deleteMethod(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3855,23 +3759,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._deleteMethod(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._deleteMethod(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._deleteMethod(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._deleteMethod(profileName, endpointName, options, optionalCallback); } } /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3889,11 +3790,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - startWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + startWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._start(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._start(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3906,9 +3807,6 @@ class Endpoints { /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3942,7 +3840,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - start(resourceGroupName, profileName, endpointName, options, optionalCallback) { + start(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3951,23 +3849,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._start(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._start(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._start(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._start(profileName, endpointName, options, optionalCallback); } } /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3985,11 +3880,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - stopWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + stopWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._stop(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._stop(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4002,9 +3897,6 @@ class Endpoints { /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4038,7 +3930,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - stop(resourceGroupName, profileName, endpointName, options, optionalCallback) { + stop(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4047,23 +3939,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._stop(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._stop(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._stop(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._stop(profileName, endpointName, options, optionalCallback); } } /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4084,11 +3973,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - purgeContentWithHttpOperationResponse(resourceGroupName, profileName, endpointName, contentPaths, options) { + purgeContentWithHttpOperationResponse(profileName, endpointName, contentPaths, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._purgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._purgeContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4101,9 +3990,6 @@ class Endpoints { /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4139,7 +4025,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - purgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback) { + purgeContent(profileName, endpointName, contentPaths, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4148,23 +4034,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._purgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._purgeContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._purgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback); + return self._purgeContent(profileName, endpointName, contentPaths, options, optionalCallback); } } /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4185,11 +4068,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - loadContentWithHttpOperationResponse(resourceGroupName, profileName, endpointName, contentPaths, options) { + loadContentWithHttpOperationResponse(profileName, endpointName, contentPaths, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._loadContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._loadContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4202,9 +4085,6 @@ class Endpoints { /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4240,7 +4120,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - loadContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback) { + loadContent(profileName, endpointName, contentPaths, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4249,14 +4129,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._loadContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._loadContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._loadContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback); + return self._loadContent(profileName, endpointName, contentPaths, options, optionalCallback); } } @@ -4264,9 +4144,6 @@ class Endpoints { * Validates the custom domain mapping to ensure it maps to the correct CDN * endpoint in DNS. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4287,11 +4164,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - validateCustomDomainWithHttpOperationResponse(resourceGroupName, profileName, endpointName, hostName, options) { + validateCustomDomainWithHttpOperationResponse(profileName, endpointName, hostName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._validateCustomDomain(resourceGroupName, profileName, endpointName, hostName, options, (err, result, request, response) => { + self._validateCustomDomain(profileName, endpointName, hostName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4305,9 +4182,6 @@ class Endpoints { * Validates the custom domain mapping to ensure it maps to the correct CDN * endpoint in DNS. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4345,7 +4219,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - validateCustomDomain(resourceGroupName, profileName, endpointName, hostName, options, optionalCallback) { + validateCustomDomain(profileName, endpointName, hostName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4354,14 +4228,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._validateCustomDomain(resourceGroupName, profileName, endpointName, hostName, options, (err, result, request, response) => { + self._validateCustomDomain(profileName, endpointName, hostName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._validateCustomDomain(resourceGroupName, profileName, endpointName, hostName, options, optionalCallback); + return self._validateCustomDomain(profileName, endpointName, hostName, options, optionalCallback); } } @@ -4369,9 +4243,6 @@ class Endpoints { * Checks the quota and usage of geo filters and custom domains under the given * endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4389,11 +4260,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - listResourceUsageWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + listResourceUsageWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listResourceUsage(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._listResourceUsage(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4407,9 +4278,6 @@ class Endpoints { * Checks the quota and usage of geo filters and custom domains under the given * endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4444,7 +4312,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listResourceUsage(resourceGroupName, profileName, endpointName, options, optionalCallback) { + listResourceUsage(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4453,14 +4321,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listResourceUsage(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._listResourceUsage(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listResourceUsage(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._listResourceUsage(profileName, endpointName, options, optionalCallback); } } @@ -4468,9 +4336,6 @@ class Endpoints { * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4534,9 +4399,6 @@ class Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -4552,11 +4414,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName, profileName, endpointName, endpoint, options) { + beginCreateWithHttpOperationResponse(profileName, endpointName, endpoint, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginCreate(resourceGroupName, profileName, endpointName, endpoint, options, (err, result, request, response) => { + self._beginCreate(profileName, endpointName, endpoint, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4570,9 +4432,6 @@ class Endpoints { * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4636,9 +4495,6 @@ class Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -4670,7 +4526,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName, profileName, endpointName, endpoint, options, optionalCallback) { + beginCreate(profileName, endpointName, endpoint, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4679,14 +4535,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginCreate(resourceGroupName, profileName, endpointName, endpoint, options, (err, result, request, response) => { + self._beginCreate(profileName, endpointName, endpoint, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginCreate(resourceGroupName, profileName, endpointName, endpoint, options, optionalCallback); + return self._beginCreate(profileName, endpointName, endpoint, options, optionalCallback); } } @@ -4697,9 +4553,6 @@ class Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4782,11 +4635,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options) { + beginUpdateWithHttpOperationResponse(profileName, endpointName, endpointUpdateProperties, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginUpdate(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { + self._beginUpdate(profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4803,9 +4656,6 @@ class Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4904,7 +4754,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, optionalCallback) { + beginUpdate(profileName, endpointName, endpointUpdateProperties, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -4913,14 +4763,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginUpdate(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { + self._beginUpdate(profileName, endpointName, endpointUpdateProperties, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginUpdate(resourceGroupName, profileName, endpointName, endpointUpdateProperties, options, optionalCallback); + return self._beginUpdate(profileName, endpointName, endpointUpdateProperties, options, optionalCallback); } } @@ -4928,9 +4778,6 @@ class Endpoints { * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -4948,11 +4795,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + beginDeleteMethodWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginDeleteMethod(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._beginDeleteMethod(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -4966,9 +4813,6 @@ class Endpoints { * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5001,7 +4845,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName, profileName, endpointName, options, optionalCallback) { + beginDeleteMethod(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -5010,23 +4854,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginDeleteMethod(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._beginDeleteMethod(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginDeleteMethod(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._beginDeleteMethod(profileName, endpointName, options, optionalCallback); } } /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5044,11 +4885,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginStartWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + beginStartWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginStart(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._beginStart(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -5061,9 +4902,6 @@ class Endpoints { /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5097,7 +4935,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginStart(resourceGroupName, profileName, endpointName, options, optionalCallback) { + beginStart(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -5106,23 +4944,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginStart(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._beginStart(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginStart(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._beginStart(profileName, endpointName, options, optionalCallback); } } /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5140,11 +4975,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginStopWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + beginStopWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginStop(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._beginStop(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -5157,9 +4992,6 @@ class Endpoints { /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5193,7 +5025,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginStop(resourceGroupName, profileName, endpointName, options, optionalCallback) { + beginStop(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -5202,23 +5034,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginStop(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._beginStop(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginStop(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._beginStop(profileName, endpointName, options, optionalCallback); } } /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5239,11 +5068,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginPurgeContentWithHttpOperationResponse(resourceGroupName, profileName, endpointName, contentPaths, options) { + beginPurgeContentWithHttpOperationResponse(profileName, endpointName, contentPaths, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginPurgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._beginPurgeContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -5256,9 +5085,6 @@ class Endpoints { /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5294,7 +5120,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginPurgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback) { + beginPurgeContent(profileName, endpointName, contentPaths, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -5303,23 +5129,20 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginPurgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._beginPurgeContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginPurgeContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback); + return self._beginPurgeContent(profileName, endpointName, contentPaths, options, optionalCallback); } } /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5340,11 +5163,11 @@ class Endpoints { * * @reject {Error} - The error object. */ - beginLoadContentWithHttpOperationResponse(resourceGroupName, profileName, endpointName, contentPaths, options) { + beginLoadContentWithHttpOperationResponse(profileName, endpointName, contentPaths, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginLoadContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._beginLoadContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -5357,9 +5180,6 @@ class Endpoints { /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -5395,7 +5215,7 @@ class Endpoints { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginLoadContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback) { + beginLoadContent(profileName, endpointName, contentPaths, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -5404,14 +5224,14 @@ class Endpoints { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginLoadContent(resourceGroupName, profileName, endpointName, contentPaths, options, (err, result, request, response) => { + self._beginLoadContent(profileName, endpointName, contentPaths, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginLoadContent(resourceGroupName, profileName, endpointName, contentPaths, options, optionalCallback); + return self._beginLoadContent(profileName, endpointName, contentPaths, options, optionalCallback); } } diff --git a/lib/services/cdnManagement/lib/operations/index.d.ts b/lib/services/cdnManagement/lib/operations/index.d.ts index 36e3cdb363..5400478fb3 100644 --- a/lib/services/cdnManagement/lib/operations/index.d.ts +++ b/lib/services/cdnManagement/lib/operations/index.d.ts @@ -75,9 +75,6 @@ export interface Profiles { /** * Lists all of the CDN profiles within a resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -89,14 +86,11 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Lists all of the CDN profiles within a resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -124,18 +118,15 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; - listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroup(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(callback: ServiceCallback): void; + listByResourceGroup(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets a CDN profile with the specified profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -150,15 +141,12 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets a CDN profile with the specified profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -189,18 +177,15 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(profileName: string, callback: ServiceCallback): void; + get(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -228,15 +213,12 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - createWithHttpOperationResponse(resourceGroupName: string, profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createWithHttpOperationResponse(profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -280,18 +262,15 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName: string, profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - create(resourceGroupName: string, profileName: string, profile: models.Profile, callback: ServiceCallback): void; - create(resourceGroupName: string, profileName: string, profile: models.Profile, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + create(profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + create(profileName: string, profile: models.Profile, callback: ServiceCallback): void; + create(profileName: string, profile: models.Profile, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -308,15 +287,12 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -349,9 +325,9 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - update(resourceGroupName: string, profileName: string, options: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise; + update(profileName: string, callback: ServiceCallback): void; + update(profileName: string, options: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -359,9 +335,6 @@ export interface Profiles { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -376,16 +349,13 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Deletes an existing CDN profile with the specified parameters. Deleting a * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -415,9 +385,9 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(profileName: string, callback: ServiceCallback): void; + deleteMethod(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -428,9 +398,6 @@ export interface Profiles { * and alerts in a premium profile. The SSO URI changes approximately every 10 * minutes. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -445,7 +412,7 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - generateSsoUriWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + generateSsoUriWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Generates a dynamic SSO URI used to sign in to the CDN supplemental portal. @@ -455,9 +422,6 @@ export interface Profiles { * and alerts in a premium profile. The SSO URI changes approximately every 10 * minutes. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -488,18 +452,15 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - generateSsoUri(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - generateSsoUri(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - generateSsoUri(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + generateSsoUri(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + generateSsoUri(profileName: string, callback: ServiceCallback): void; + generateSsoUri(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets the supported optimization types for the current profile. A user can * create an endpoint with an optimization type from the listed values. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -514,15 +475,12 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - listSupportedOptimizationTypesWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listSupportedOptimizationTypesWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets the supported optimization types for the current profile. A user can * create an endpoint with an optimization type from the listed values. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -554,17 +512,14 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listSupportedOptimizationTypes(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listSupportedOptimizationTypes(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - listSupportedOptimizationTypes(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listSupportedOptimizationTypes(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listSupportedOptimizationTypes(profileName: string, callback: ServiceCallback): void; + listSupportedOptimizationTypes(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Checks the quota and actual usage of endpoints under the given CDN profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -579,14 +534,11 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - listResourceUsageWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listResourceUsageWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Checks the quota and actual usage of endpoints under the given CDN profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -618,18 +570,15 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listResourceUsage(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listResourceUsage(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - listResourceUsage(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listResourceUsage(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listResourceUsage(profileName: string, callback: ServiceCallback): void; + listResourceUsage(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -657,15 +606,12 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName: string, profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateWithHttpOperationResponse(profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -709,18 +655,15 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName: string, profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreate(resourceGroupName: string, profileName: string, profile: models.Profile, callback: ServiceCallback): void; - beginCreate(resourceGroupName: string, profileName: string, profile: models.Profile, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreate(profileName: string, profile: models.Profile, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreate(profileName: string, profile: models.Profile, callback: ServiceCallback): void; + beginCreate(profileName: string, profile: models.Profile, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -737,15 +680,12 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -778,9 +718,9 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, profileName: string, options: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(profileName: string, options?: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(profileName: string, callback: ServiceCallback): void; + beginUpdate(profileName: string, options: { tags? : { [propertyName: string]: string }, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -788,9 +728,6 @@ export interface Profiles { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -805,16 +742,13 @@ export interface Profiles { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Deletes an existing CDN profile with the specified parameters. Deleting a * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -844,9 +778,9 @@ export interface Profiles { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(profileName: string, callback: ServiceCallback): void; + beginDeleteMethod(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -1033,9 +967,6 @@ export interface Endpoints { /** * Lists existing CDN endpoints. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1050,14 +981,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - listByProfileWithHttpOperationResponse(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByProfileWithHttpOperationResponse(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Lists existing CDN endpoints. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1088,18 +1016,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByProfile(resourceGroupName: string, profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByProfile(resourceGroupName: string, profileName: string, callback: ServiceCallback): void; - listByProfile(resourceGroupName: string, profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByProfile(profileName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByProfile(profileName: string, callback: ServiceCallback): void; + listByProfile(profileName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1117,15 +1042,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1159,18 +1081,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(profileName: string, endpointName: string, callback: ServiceCallback): void; + get(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1234,9 +1153,6 @@ export interface Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -1252,15 +1168,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - createWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createWithHttpOperationResponse(profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1324,9 +1237,6 @@ export interface Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -1358,9 +1268,9 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - create(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, callback: ServiceCallback): void; - create(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + create(profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + create(profileName: string, endpointName: string, endpoint: models.Endpoint, callback: ServiceCallback): void; + create(profileName: string, endpointName: string, endpoint: models.Endpoint, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -1370,9 +1280,6 @@ export interface Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1455,7 +1362,7 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an existing CDN endpoint with the specified endpoint name under the @@ -1464,9 +1371,6 @@ export interface Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1565,18 +1469,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, callback: ServiceCallback): void; - update(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, callback: ServiceCallback): void; + update(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1594,15 +1495,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1635,17 +1533,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(profileName: string, endpointName: string, callback: ServiceCallback): void; + deleteMethod(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1663,14 +1558,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - startWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + startWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1704,17 +1596,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - start(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - start(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - start(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + start(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + start(profileName: string, endpointName: string, callback: ServiceCallback): void; + start(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1732,14 +1621,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - stopWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + stopWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1773,17 +1659,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - stop(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - stop(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - stop(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + stop(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + stop(profileName: string, endpointName: string, callback: ServiceCallback): void; + stop(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1804,14 +1687,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - purgeContentWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + purgeContentWithHttpOperationResponse(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1847,17 +1727,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - purgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - purgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; - purgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + purgeContent(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + purgeContent(profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; + purgeContent(profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1878,14 +1755,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - loadContentWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + loadContentWithHttpOperationResponse(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1921,18 +1795,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - loadContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - loadContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; - loadContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + loadContent(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + loadContent(profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; + loadContent(profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Validates the custom domain mapping to ensure it maps to the correct CDN * endpoint in DNS. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1953,15 +1824,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - validateCustomDomainWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + validateCustomDomainWithHttpOperationResponse(profileName: string, endpointName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Validates the custom domain mapping to ensure it maps to the correct CDN * endpoint in DNS. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1999,18 +1867,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, callback: ServiceCallback): void; - validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + validateCustomDomain(profileName: string, endpointName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + validateCustomDomain(profileName: string, endpointName: string, hostName: string, callback: ServiceCallback): void; + validateCustomDomain(profileName: string, endpointName: string, hostName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Checks the quota and usage of geo filters and custom domains under the given * endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2028,15 +1893,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - listResourceUsageWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listResourceUsageWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Checks the quota and usage of geo filters and custom domains under the given * endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2071,18 +1933,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listResourceUsage(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listResourceUsage(profileName: string, endpointName: string, callback: ServiceCallback): void; + listResourceUsage(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2146,9 +2005,6 @@ export interface Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -2164,15 +2020,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateWithHttpOperationResponse(profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates a new CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2236,9 +2089,6 @@ export interface Endpoints { * * @param {array} endpoint.deliveryPolicy.rules A list of the delivery rules. * - * @param {array} endpoint.origins The source of the content being delivered - * via CDN. - * * @param {string} endpoint.location Resource location. * * @param {object} [endpoint.tags] Resource tags. @@ -2270,9 +2120,9 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, callback: ServiceCallback): void; - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, endpoint: models.Endpoint, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreate(profileName: string, endpointName: string, endpoint: models.Endpoint, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreate(profileName: string, endpointName: string, endpoint: models.Endpoint, callback: ServiceCallback): void; + beginCreate(profileName: string, endpointName: string, endpoint: models.Endpoint, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -2282,9 +2132,6 @@ export interface Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2367,7 +2214,7 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an existing CDN endpoint with the specified endpoint name under the @@ -2376,9 +2223,6 @@ export interface Endpoints { * the Update Origin operation. To update custom domains, use the Update Custom * Domain operation. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2477,18 +2321,15 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, callback: ServiceCallback): void; + beginUpdate(profileName: string, endpointName: string, endpointUpdateProperties: models.EndpointUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2506,15 +2347,12 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Deletes an existing CDN endpoint with the specified endpoint name under the * specified subscription, resource group and profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2547,17 +2385,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(profileName: string, endpointName: string, callback: ServiceCallback): void; + beginDeleteMethod(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2575,14 +2410,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginStartWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStartWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Starts an existing CDN endpoint that is on a stopped state. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2616,17 +2448,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStart(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStart(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - beginStart(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginStart(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStart(profileName: string, endpointName: string, callback: ServiceCallback): void; + beginStart(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2644,14 +2473,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginStopWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginStopWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Stops an existing running CDN endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2685,17 +2511,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginStop(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginStop(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - beginStop(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginStop(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginStop(profileName: string, endpointName: string, callback: ServiceCallback): void; + beginStop(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2716,14 +2539,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginPurgeContentWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginPurgeContentWithHttpOperationResponse(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Removes a content from CDN. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2759,17 +2579,14 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginPurgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginPurgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; - beginPurgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginPurgeContent(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginPurgeContent(profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; + beginPurgeContent(profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2790,14 +2607,11 @@ export interface Endpoints { * * @reject {Error|ServiceError} - The error object. */ - beginLoadContentWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginLoadContentWithHttpOperationResponse(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Pre-loads a content to CDN. Available for Verizon Profiles. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2833,9 +2647,9 @@ export interface Endpoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginLoadContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginLoadContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; - beginLoadContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginLoadContent(profileName: string, endpointName: string, contentPaths: string[], options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginLoadContent(profileName: string, endpointName: string, contentPaths: string[], callback: ServiceCallback): void; + beginLoadContent(profileName: string, endpointName: string, contentPaths: string[], options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -2967,9 +2781,6 @@ export interface Origins { /** * Lists all of the existing origins within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2987,14 +2798,11 @@ export interface Origins { * * @reject {Error|ServiceError} - The error object. */ - listByEndpointWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByEndpointWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Lists all of the existing origins within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3028,17 +2836,14 @@ export interface Origins { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByEndpoint(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByEndpoint(profileName: string, endpointName: string, callback: ServiceCallback): void; + listByEndpoint(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3059,14 +2864,11 @@ export interface Origins { * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, originName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(profileName: string, endpointName: string, originName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3103,17 +2905,14 @@ export interface Origins { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, profileName: string, endpointName: string, originName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, profileName: string, endpointName: string, originName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, profileName: string, endpointName: string, originName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(profileName: string, endpointName: string, originName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(profileName: string, endpointName: string, originName: string, callback: ServiceCallback): void; + get(profileName: string, endpointName: string, originName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3145,14 +2944,11 @@ export interface Origins { * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3200,17 +2996,14 @@ export interface Origins { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, callback: ServiceCallback): void; - update(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, callback: ServiceCallback): void; + update(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3242,14 +3035,11 @@ export interface Origins { * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3297,9 +3087,9 @@ export interface Origins { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, callback: ServiceCallback): void; + beginUpdate(profileName: string, endpointName: string, originName: string, originUpdateProperties: models.OriginUpdateParameters, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -3371,9 +3161,6 @@ export interface CustomDomains { /** * Lists all of the existing custom domains within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3391,14 +3178,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - listByEndpointWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByEndpointWithHttpOperationResponse(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Lists all of the existing custom domains within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3433,17 +3217,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, callback: ServiceCallback): void; - listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByEndpoint(profileName: string, endpointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByEndpoint(profileName: string, endpointName: string, callback: ServiceCallback): void; + listByEndpoint(profileName: string, endpointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Gets an exisitng custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3464,14 +3245,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets an exisitng custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3508,17 +3286,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; + get(profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3542,14 +3317,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - createWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3589,17 +3361,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - create(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, callback: ServiceCallback): void; - create(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + create(profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + create(profileName: string, endpointName: string, customDomainName: string, hostName: string, callback: ServiceCallback): void; + create(profileName: string, endpointName: string, customDomainName: string, hostName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3620,14 +3389,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3664,17 +3430,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; + deleteMethod(profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Disable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3695,14 +3458,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - disableCustomHttpsWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + disableCustomHttpsWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Disable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3739,17 +3499,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + disableCustomHttps(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + disableCustomHttps(profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; + disableCustomHttps(profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Enable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3770,14 +3527,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - enableCustomHttpsWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + enableCustomHttpsWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Enable https delivery of the custom domain. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3814,17 +3568,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + enableCustomHttps(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + enableCustomHttps(profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; + enableCustomHttps(profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3848,14 +3599,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Creates a new custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3895,17 +3643,14 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, callback: ServiceCallback): void; - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreate(profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreate(profileName: string, endpointName: string, customDomainName: string, hostName: string, callback: ServiceCallback): void; + beginCreate(profileName: string, endpointName: string, customDomainName: string, hostName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3926,14 +3671,11 @@ export interface CustomDomains { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Deletes an existing custom domain within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3970,9 +3712,9 @@ export interface CustomDomains { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(profileName: string, endpointName: string, customDomainName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(profileName: string, endpointName: string, customDomainName: string, callback: ServiceCallback): void; + beginDeleteMethod(profileName: string, endpointName: string, customDomainName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** diff --git a/lib/services/cdnManagement/lib/operations/origins.js b/lib/services/cdnManagement/lib/operations/origins.js index deda4fd783..cfa70f9aa8 100644 --- a/lib/services/cdnManagement/lib/operations/origins.js +++ b/lib/services/cdnManagement/lib/operations/origins.js @@ -17,9 +17,6 @@ const WebResource = msRest.WebResource; /** * Lists all of the existing origins within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -44,7 +41,7 @@ const WebResource = msRest.WebResource; * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listByEndpoint(resourceGroupName, profileName, endpointName, options, callback) { +function _listByEndpoint(profileName, endpointName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -56,21 +53,21 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -95,7 +92,7 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); @@ -186,9 +183,6 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, /** * Gets an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -216,7 +210,7 @@ function _listByEndpoint(resourceGroupName, profileName, endpointName, options, * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _get(resourceGroupName, profileName, endpointName, originName, options, callback) { +function _get(profileName, endpointName, originName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -228,21 +222,21 @@ function _get(resourceGroupName, profileName, endpointName, originName, options, } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -270,7 +264,7 @@ function _get(resourceGroupName, profileName, endpointName, originName, options, // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins/{originName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{originName}', encodeURIComponent(originName)); @@ -363,9 +357,6 @@ function _get(resourceGroupName, profileName, endpointName, originName, options, /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -404,7 +395,7 @@ function _get(resourceGroupName, profileName, endpointName, originName, options, * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _update(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, callback) { +function _update(profileName, endpointName, originName, originUpdateProperties, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -417,7 +408,7 @@ function _update(resourceGroupName, profileName, endpointName, originName, origi } // Send request - this.beginUpdate(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, (err, parsedResult, httpRequest, response) => { + this.beginUpdate(profileName, endpointName, originName, originUpdateProperties, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -459,9 +450,6 @@ function _update(resourceGroupName, profileName, endpointName, originName, origi /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -500,7 +488,7 @@ function _update(resourceGroupName, profileName, endpointName, originName, origi * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginUpdate(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, callback) { +function _beginUpdate(profileName, endpointName, originName, originUpdateProperties, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -512,21 +500,21 @@ function _beginUpdate(resourceGroupName, profileName, endpointName, originName, } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -557,7 +545,7 @@ function _beginUpdate(resourceGroupName, profileName, endpointName, originName, // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins/{originName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{endpointName}', encodeURIComponent(endpointName)); requestUrl = requestUrl.replace('{originName}', encodeURIComponent(originName)); @@ -823,9 +811,6 @@ class Origins { /** * Lists all of the existing origins within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -843,11 +828,11 @@ class Origins { * * @reject {Error} - The error object. */ - listByEndpointWithHttpOperationResponse(resourceGroupName, profileName, endpointName, options) { + listByEndpointWithHttpOperationResponse(profileName, endpointName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listByEndpoint(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._listByEndpoint(profileName, endpointName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -860,9 +845,6 @@ class Origins { /** * Lists all of the existing origins within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -896,7 +878,7 @@ class Origins { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listByEndpoint(resourceGroupName, profileName, endpointName, options, optionalCallback) { + listByEndpoint(profileName, endpointName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -905,23 +887,20 @@ class Origins { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listByEndpoint(resourceGroupName, profileName, endpointName, options, (err, result, request, response) => { + self._listByEndpoint(profileName, endpointName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listByEndpoint(resourceGroupName, profileName, endpointName, options, optionalCallback); + return self._listByEndpoint(profileName, endpointName, options, optionalCallback); } } /** * Gets an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -942,11 +921,11 @@ class Origins { * * @reject {Error} - The error object. */ - getWithHttpOperationResponse(resourceGroupName, profileName, endpointName, originName, options) { + getWithHttpOperationResponse(profileName, endpointName, originName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, endpointName, originName, options, (err, result, request, response) => { + self._get(profileName, endpointName, originName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -959,9 +938,6 @@ class Origins { /** * Gets an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -998,7 +974,7 @@ class Origins { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName, profileName, endpointName, originName, options, optionalCallback) { + get(profileName, endpointName, originName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1007,23 +983,20 @@ class Origins { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, endpointName, originName, options, (err, result, request, response) => { + self._get(profileName, endpointName, originName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._get(resourceGroupName, profileName, endpointName, originName, options, optionalCallback); + return self._get(profileName, endpointName, originName, options, optionalCallback); } } /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1055,11 +1028,11 @@ class Origins { * * @reject {Error} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options) { + updateWithHttpOperationResponse(profileName, endpointName, originName, originUpdateProperties, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._update(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { + self._update(profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1072,9 +1045,6 @@ class Origins { /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1122,7 +1092,7 @@ class Origins { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, optionalCallback) { + update(profileName, endpointName, originName, originUpdateProperties, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1131,23 +1101,20 @@ class Origins { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._update(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { + self._update(profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._update(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, optionalCallback); + return self._update(profileName, endpointName, originName, originUpdateProperties, options, optionalCallback); } } /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1179,11 +1146,11 @@ class Origins { * * @reject {Error} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options) { + beginUpdateWithHttpOperationResponse(profileName, endpointName, originName, originUpdateProperties, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginUpdate(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { + self._beginUpdate(profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -1196,9 +1163,6 @@ class Origins { /** * Updates an existing origin within an endpoint. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1246,7 +1210,7 @@ class Origins { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, optionalCallback) { + beginUpdate(profileName, endpointName, originName, originUpdateProperties, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -1255,14 +1219,14 @@ class Origins { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginUpdate(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { + self._beginUpdate(profileName, endpointName, originName, originUpdateProperties, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginUpdate(resourceGroupName, profileName, endpointName, originName, originUpdateProperties, options, optionalCallback); + return self._beginUpdate(profileName, endpointName, originName, originUpdateProperties, options, optionalCallback); } } diff --git a/lib/services/cdnManagement/lib/operations/profiles.js b/lib/services/cdnManagement/lib/operations/profiles.js index 0a07e606a2..933b3b79ef 100644 --- a/lib/services/cdnManagement/lib/operations/profiles.js +++ b/lib/services/cdnManagement/lib/operations/profiles.js @@ -151,9 +151,6 @@ function _list(options, callback) { /** * Lists all of the CDN profiles within a resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -172,7 +169,7 @@ function _list(options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listByResourceGroup(resourceGroupName, options, callback) { +function _listByResourceGroup(options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -184,21 +181,21 @@ function _listByResourceGroup(resourceGroupName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { @@ -217,7 +214,7 @@ function _listByResourceGroup(resourceGroupName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); @@ -307,9 +304,6 @@ function _listByResourceGroup(resourceGroupName, options, callback) { * Gets a CDN profile with the specified profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -331,7 +325,7 @@ function _listByResourceGroup(resourceGroupName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _get(resourceGroupName, profileName, options, callback) { +function _get(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -343,21 +337,21 @@ function _get(resourceGroupName, profileName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -379,7 +373,7 @@ function _get(resourceGroupName, profileName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -471,9 +465,6 @@ function _get(resourceGroupName, profileName, options, callback) { * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -508,7 +499,7 @@ function _get(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _create(resourceGroupName, profileName, profile, options, callback) { +function _create(profileName, profile, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -521,7 +512,7 @@ function _create(resourceGroupName, profileName, profile, options, callback) { } // Send request - this.beginCreate(resourceGroupName, profileName, profile, options, (err, parsedResult, httpRequest, response) => { + this.beginCreate(profileName, profile, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -565,9 +556,6 @@ function _create(resourceGroupName, profileName, profile, options, callback) { * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -591,7 +579,7 @@ function _create(resourceGroupName, profileName, profile, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _update(resourceGroupName, profileName, options, callback) { +function _update(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -604,7 +592,7 @@ function _update(resourceGroupName, profileName, options, callback) { } // Send request - this.beginUpdate(resourceGroupName, profileName, options, (err, parsedResult, httpRequest, response) => { + this.beginUpdate(profileName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -649,9 +637,6 @@ function _update(resourceGroupName, profileName, options, callback) { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -672,7 +657,7 @@ function _update(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _deleteMethod(resourceGroupName, profileName, options, callback) { +function _deleteMethod(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -685,7 +670,7 @@ function _deleteMethod(resourceGroupName, profileName, options, callback) { } // Send request - this.beginDeleteMethod(resourceGroupName, profileName, options, (err, parsedResult, httpRequest, response) => { + this.beginDeleteMethod(profileName, options, (err, parsedResult, httpRequest, response) => { if (err) return callback(err); let initialResult = new msRest.HttpOperationResponse(); @@ -718,9 +703,6 @@ function _deleteMethod(resourceGroupName, profileName, options, callback) { * and alerts in a premium profile. The SSO URI changes approximately every 10 * minutes. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -742,7 +724,7 @@ function _deleteMethod(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _generateSsoUri(resourceGroupName, profileName, options, callback) { +function _generateSsoUri(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -754,21 +736,21 @@ function _generateSsoUri(resourceGroupName, profileName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -790,7 +772,7 @@ function _generateSsoUri(resourceGroupName, profileName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/generateSsoUri'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -881,9 +863,6 @@ function _generateSsoUri(resourceGroupName, profileName, options, callback) { * Gets the supported optimization types for the current profile. A user can * create an endpoint with an optimization type from the listed values. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -906,7 +885,7 @@ function _generateSsoUri(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listSupportedOptimizationTypes(resourceGroupName, profileName, options, callback) { +function _listSupportedOptimizationTypes(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -918,21 +897,21 @@ function _listSupportedOptimizationTypes(resourceGroupName, profileName, options } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -954,7 +933,7 @@ function _listSupportedOptimizationTypes(resourceGroupName, profileName, options // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getSupportedOptimizationTypes'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -1044,9 +1023,6 @@ function _listSupportedOptimizationTypes(resourceGroupName, profileName, options /** * Checks the quota and actual usage of endpoints under the given CDN profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1069,7 +1045,7 @@ function _listSupportedOptimizationTypes(resourceGroupName, profileName, options * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _listResourceUsage(resourceGroupName, profileName, options, callback) { +function _listResourceUsage(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1081,21 +1057,21 @@ function _listResourceUsage(resourceGroupName, profileName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1117,7 +1093,7 @@ function _listResourceUsage(resourceGroupName, profileName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/checkResourceUsage'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -1208,9 +1184,6 @@ function _listResourceUsage(resourceGroupName, profileName, options, callback) { * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1245,7 +1218,7 @@ function _listResourceUsage(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginCreate(resourceGroupName, profileName, profile, options, callback) { +function _beginCreate(profileName, profile, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1257,21 +1230,21 @@ function _beginCreate(resourceGroupName, profileName, profile, options, callback } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1296,7 +1269,7 @@ function _beginCreate(resourceGroupName, profileName, profile, options, callback // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -1435,9 +1408,6 @@ function _beginCreate(resourceGroupName, profileName, profile, options, callback * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1461,7 +1431,7 @@ function _beginCreate(resourceGroupName, profileName, profile, options, callback * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginUpdate(resourceGroupName, profileName, options, callback) { +function _beginUpdate(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1474,21 +1444,21 @@ function _beginUpdate(resourceGroupName, profileName, options, callback) { let tags = (options && options.tags !== undefined) ? options.tags : undefined; // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1522,7 +1492,7 @@ function _beginUpdate(resourceGroupName, profileName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -1645,9 +1615,6 @@ function _beginUpdate(resourceGroupName, profileName, options, callback) { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -1668,7 +1635,7 @@ function _beginUpdate(resourceGroupName, profileName, options, callback) { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ -function _beginDeleteMethod(resourceGroupName, profileName, options, callback) { +function _beginDeleteMethod(profileName, options, callback) { /* jshint validthis: true */ let client = this.client; if(!callback && typeof options === 'function') { @@ -1680,21 +1647,21 @@ function _beginDeleteMethod(resourceGroupName, profileName, options, callback) { } // Validate try { - if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { - throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + if (this.client.resourceGroupName === null || this.client.resourceGroupName === undefined || typeof this.client.resourceGroupName.valueOf() !== 'string') { + throw new Error('this.client.resourceGroupName cannot be null or undefined and it must be of type string.'); } - if (resourceGroupName !== null && resourceGroupName !== undefined) { - if (resourceGroupName.length > 90) + if (this.client.resourceGroupName !== null && this.client.resourceGroupName !== undefined) { + if (this.client.resourceGroupName.length > 90) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MaxLength": 90'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MaxLength": 90'); } - if (resourceGroupName.length < 1) + if (this.client.resourceGroupName.length < 1) { - throw new Error('"resourceGroupName" should satisfy the constraint - "MinLength": 1'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "MinLength": 1'); } - if (resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) + if (this.client.resourceGroupName.match(/^[-\w\._\(\)]+$/) === null) { - throw new Error('"resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); + throw new Error('"this.client.resourceGroupName" should satisfy the constraint - "Pattern": /^[-\w\._\(\)]+$/'); } } if (profileName === null || profileName === undefined || typeof profileName.valueOf() !== 'string') { @@ -1716,7 +1683,7 @@ function _beginDeleteMethod(resourceGroupName, profileName, options, callback) { // Construct URL let baseUrl = this.client.baseUri; let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}'; - requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(this.client.resourceGroupName)); requestUrl = requestUrl.replace('{profileName}', encodeURIComponent(profileName)); requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; @@ -2277,9 +2244,6 @@ class Profiles { /** * Lists all of the CDN profiles within a resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -2291,11 +2255,11 @@ class Profiles { * * @reject {Error} - The error object. */ - listByResourceGroupWithHttpOperationResponse(resourceGroupName, options) { + listByResourceGroupWithHttpOperationResponse(options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + self._listByResourceGroup(options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2308,9 +2272,6 @@ class Profiles { /** * Lists all of the CDN profiles within a resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -2338,7 +2299,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroup(resourceGroupName, options, optionalCallback) { + listByResourceGroup(options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2347,14 +2308,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listByResourceGroup(resourceGroupName, options, (err, result, request, response) => { + self._listByResourceGroup(options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listByResourceGroup(resourceGroupName, options, optionalCallback); + return self._listByResourceGroup(options, optionalCallback); } } @@ -2362,9 +2323,6 @@ class Profiles { * Gets a CDN profile with the specified profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2379,11 +2337,11 @@ class Profiles { * * @reject {Error} - The error object. */ - getWithHttpOperationResponse(resourceGroupName, profileName, options) { + getWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, options, (err, result, request, response) => { + self._get(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2397,9 +2355,6 @@ class Profiles { * Gets a CDN profile with the specified profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2430,7 +2385,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName, profileName, options, optionalCallback) { + get(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2439,14 +2394,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._get(resourceGroupName, profileName, options, (err, result, request, response) => { + self._get(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._get(resourceGroupName, profileName, options, optionalCallback); + return self._get(profileName, options, optionalCallback); } } @@ -2454,9 +2409,6 @@ class Profiles { * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2484,11 +2436,11 @@ class Profiles { * * @reject {Error} - The error object. */ - createWithHttpOperationResponse(resourceGroupName, profileName, profile, options) { + createWithHttpOperationResponse(profileName, profile, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._create(resourceGroupName, profileName, profile, options, (err, result, request, response) => { + self._create(profileName, profile, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2502,9 +2454,6 @@ class Profiles { * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2548,7 +2497,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName, profileName, profile, options, optionalCallback) { + create(profileName, profile, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2557,14 +2506,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._create(resourceGroupName, profileName, profile, options, (err, result, request, response) => { + self._create(profileName, profile, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._create(resourceGroupName, profileName, profile, options, optionalCallback); + return self._create(profileName, profile, options, optionalCallback); } } @@ -2572,9 +2521,6 @@ class Profiles { * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2591,11 +2537,11 @@ class Profiles { * * @reject {Error} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName, profileName, options) { + updateWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._update(resourceGroupName, profileName, options, (err, result, request, response) => { + self._update(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2609,9 +2555,6 @@ class Profiles { * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2644,7 +2587,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName, profileName, options, optionalCallback) { + update(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2653,14 +2596,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._update(resourceGroupName, profileName, options, (err, result, request, response) => { + self._update(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._update(resourceGroupName, profileName, options, optionalCallback); + return self._update(profileName, options, optionalCallback); } } @@ -2669,9 +2612,6 @@ class Profiles { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2686,11 +2626,11 @@ class Profiles { * * @reject {Error} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName, profileName, options) { + deleteMethodWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._deleteMethod(resourceGroupName, profileName, options, (err, result, request, response) => { + self._deleteMethod(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2705,9 +2645,6 @@ class Profiles { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2737,7 +2674,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName, profileName, options, optionalCallback) { + deleteMethod(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2746,14 +2683,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._deleteMethod(resourceGroupName, profileName, options, (err, result, request, response) => { + self._deleteMethod(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._deleteMethod(resourceGroupName, profileName, options, optionalCallback); + return self._deleteMethod(profileName, options, optionalCallback); } } @@ -2765,9 +2702,6 @@ class Profiles { * and alerts in a premium profile. The SSO URI changes approximately every 10 * minutes. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2782,11 +2716,11 @@ class Profiles { * * @reject {Error} - The error object. */ - generateSsoUriWithHttpOperationResponse(resourceGroupName, profileName, options) { + generateSsoUriWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._generateSsoUri(resourceGroupName, profileName, options, (err, result, request, response) => { + self._generateSsoUri(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2804,9 +2738,6 @@ class Profiles { * and alerts in a premium profile. The SSO URI changes approximately every 10 * minutes. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2837,7 +2768,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - generateSsoUri(resourceGroupName, profileName, options, optionalCallback) { + generateSsoUri(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2846,14 +2777,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._generateSsoUri(resourceGroupName, profileName, options, (err, result, request, response) => { + self._generateSsoUri(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._generateSsoUri(resourceGroupName, profileName, options, optionalCallback); + return self._generateSsoUri(profileName, options, optionalCallback); } } @@ -2861,9 +2792,6 @@ class Profiles { * Gets the supported optimization types for the current profile. A user can * create an endpoint with an optimization type from the listed values. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2878,11 +2806,11 @@ class Profiles { * * @reject {Error} - The error object. */ - listSupportedOptimizationTypesWithHttpOperationResponse(resourceGroupName, profileName, options) { + listSupportedOptimizationTypesWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listSupportedOptimizationTypes(resourceGroupName, profileName, options, (err, result, request, response) => { + self._listSupportedOptimizationTypes(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2896,9 +2824,6 @@ class Profiles { * Gets the supported optimization types for the current profile. A user can * create an endpoint with an optimization type from the listed values. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2930,7 +2855,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listSupportedOptimizationTypes(resourceGroupName, profileName, options, optionalCallback) { + listSupportedOptimizationTypes(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -2939,23 +2864,20 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listSupportedOptimizationTypes(resourceGroupName, profileName, options, (err, result, request, response) => { + self._listSupportedOptimizationTypes(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listSupportedOptimizationTypes(resourceGroupName, profileName, options, optionalCallback); + return self._listSupportedOptimizationTypes(profileName, options, optionalCallback); } } /** * Checks the quota and actual usage of endpoints under the given CDN profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -2970,11 +2892,11 @@ class Profiles { * * @reject {Error} - The error object. */ - listResourceUsageWithHttpOperationResponse(resourceGroupName, profileName, options) { + listResourceUsageWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._listResourceUsage(resourceGroupName, profileName, options, (err, result, request, response) => { + self._listResourceUsage(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -2987,9 +2909,6 @@ class Profiles { /** * Checks the quota and actual usage of endpoints under the given CDN profile. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3021,7 +2940,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - listResourceUsage(resourceGroupName, profileName, options, optionalCallback) { + listResourceUsage(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3030,14 +2949,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._listResourceUsage(resourceGroupName, profileName, options, (err, result, request, response) => { + self._listResourceUsage(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._listResourceUsage(resourceGroupName, profileName, options, optionalCallback); + return self._listResourceUsage(profileName, options, optionalCallback); } } @@ -3045,9 +2964,6 @@ class Profiles { * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3075,11 +2991,11 @@ class Profiles { * * @reject {Error} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName, profileName, profile, options) { + beginCreateWithHttpOperationResponse(profileName, profile, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginCreate(resourceGroupName, profileName, profile, options, (err, result, request, response) => { + self._beginCreate(profileName, profile, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3093,9 +3009,6 @@ class Profiles { * Creates a new CDN profile with a profile name under the specified * subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3139,7 +3052,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName, profileName, profile, options, optionalCallback) { + beginCreate(profileName, profile, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3148,14 +3061,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginCreate(resourceGroupName, profileName, profile, options, (err, result, request, response) => { + self._beginCreate(profileName, profile, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginCreate(resourceGroupName, profileName, profile, options, optionalCallback); + return self._beginCreate(profileName, profile, options, optionalCallback); } } @@ -3163,9 +3076,6 @@ class Profiles { * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3182,11 +3092,11 @@ class Profiles { * * @reject {Error} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName, profileName, options) { + beginUpdateWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginUpdate(resourceGroupName, profileName, options, (err, result, request, response) => { + self._beginUpdate(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3200,9 +3110,6 @@ class Profiles { * Updates an existing CDN profile with the specified profile name under the * specified subscription and resource group. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3235,7 +3142,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName, profileName, options, optionalCallback) { + beginUpdate(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3244,14 +3151,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginUpdate(resourceGroupName, profileName, options, (err, result, request, response) => { + self._beginUpdate(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginUpdate(resourceGroupName, profileName, options, optionalCallback); + return self._beginUpdate(profileName, options, optionalCallback); } } @@ -3260,9 +3167,6 @@ class Profiles { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3277,11 +3181,11 @@ class Profiles { * * @reject {Error} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName, profileName, options) { + beginDeleteMethodWithHttpOperationResponse(profileName, options) { let client = this.client; let self = this; return new Promise((resolve, reject) => { - self._beginDeleteMethod(resourceGroupName, profileName, options, (err, result, request, response) => { + self._beginDeleteMethod(profileName, options, (err, result, request, response) => { let httpOperationResponse = new msRest.HttpOperationResponse(request, response); httpOperationResponse.body = result; if (err) { reject(err); } @@ -3296,9 +3200,6 @@ class Profiles { * profile will result in the deletion of all of the sub-resources including * endpoints, origins and custom domains. * - * @param {string} resourceGroupName Name of the Resource group within the - * Azure subscription. - * * @param {string} profileName Name of the CDN profile which is unique within * the resource group. * @@ -3328,7 +3229,7 @@ class Profiles { * * {stream} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName, profileName, options, optionalCallback) { + beginDeleteMethod(profileName, options, optionalCallback) { let client = this.client; let self = this; if (!optionalCallback && typeof options === 'function') { @@ -3337,14 +3238,14 @@ class Profiles { } if (!optionalCallback) { return new Promise((resolve, reject) => { - self._beginDeleteMethod(resourceGroupName, profileName, options, (err, result, request, response) => { + self._beginDeleteMethod(profileName, options, (err, result, request, response) => { if (err) { reject(err); } else { resolve(result); } return; }); }); } else { - return self._beginDeleteMethod(resourceGroupName, profileName, options, optionalCallback); + return self._beginDeleteMethod(profileName, options, optionalCallback); } } diff --git a/lib/services/cdnManagement/package.json b/lib/services/cdnManagement/package.json index a91d069fb7..c208260178 100644 --- a/lib/services/cdnManagement/package.json +++ b/lib/services/cdnManagement/package.json @@ -1,37 +1,22 @@ { "name": "azure-arm-cdn", "author": "Microsoft Corporation", - "contributors": [ - "Zarif, Injy ", - "Zavery, Amar ", - "Wan, Qinyuan " - ], + "description": "CdnManagementClient Library with typescript type definitions for node", "version": "4.0.0", - "description": "Microsoft Azure CDN Resource Provider Management Client Library for Node", - "tags": [ - "azure", - "sdk" - ], - "keywords": [ - "node", - "azure" - ], - "main": "./lib/cdnManagementClient.js", - "types": "./lib/cdnManagementClient.d.ts", - "license": "MIT", "dependencies": { - "ms-rest": "^2.3.0", - "ms-rest-azure": "^2.5.3" + "ms-rest": "^2.3.2", + "ms-rest-azure": "^2.5.5" }, - "homepage": "http://github.com/Azure/azure-sdk-for-node", + "keywords": [ "node", "azure" ], + "license": "MIT", + "main": "./lib/cdnManagementClient.js", + "types": "./lib/cdnManagementClient.d.ts", + "homepage": "http://github.com/azure/azure-sdk-for-node", "repository": { "type": "git", - "url": "git@github.com:Azure/azure-sdk-for-node.git" + "url": "https://github.com/azure/azure-sdk-for-node.git" }, "bugs": { "url": "http://github.com/Azure/azure-sdk-for-node/issues" - }, - "scripts": { - "test": "npm -s run-script jshint" } }