diff --git a/lib/services/serviceBusManagement2/lib/operations/index.d.ts b/lib/services/serviceBusManagement2/lib/operations/index.d.ts index 220deb947e..420ce3f3a6 100644 --- a/lib/services/serviceBusManagement2/lib/operations/index.d.ts +++ b/lib/services/serviceBusManagement2/lib/operations/index.d.ts @@ -2764,6 +2764,14 @@ export interface Queues { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -2773,7 +2781,7 @@ export interface Queues { * * @reject {Error|ServiceError} - The error object. */ - listByNamespaceWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByNamespaceWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets the queues within a namespace. @@ -2785,6 +2793,14 @@ export interface Queues { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -2810,9 +2826,9 @@ export interface Queues { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByNamespace(resourceGroupName: string, namespaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByNamespace(resourceGroupName: string, namespaceName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise; listByNamespace(resourceGroupName: string, namespaceName: string, callback: ServiceCallback): void; - listByNamespace(resourceGroupName: string, namespaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByNamespace(resourceGroupName: string, namespaceName: string, options: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -3697,6 +3713,14 @@ export interface Topics { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -3706,7 +3730,7 @@ export interface Topics { * * @reject {Error|ServiceError} - The error object. */ - listByNamespaceWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByNamespaceWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * Gets all the topics in a namespace. @@ -3718,6 +3742,14 @@ export interface Topics { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -3743,9 +3775,9 @@ export interface Topics { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByNamespace(resourceGroupName: string, namespaceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByNamespace(resourceGroupName: string, namespaceName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise; listByNamespace(resourceGroupName: string, namespaceName: string, callback: ServiceCallback): void; - listByNamespace(resourceGroupName: string, namespaceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByNamespace(resourceGroupName: string, namespaceName: string, options: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -4596,6 +4628,14 @@ export interface Subscriptions { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -4605,7 +4645,7 @@ export interface Subscriptions { * * @reject {Error|ServiceError} - The error object. */ - listByTopicWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, topicName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByTopicWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, topicName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * List all the subscriptions under a specified topic. @@ -4619,6 +4659,14 @@ export interface Subscriptions { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -4645,9 +4693,9 @@ export interface Subscriptions { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByTopic(resourceGroupName: string, namespaceName: string, topicName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByTopic(resourceGroupName: string, namespaceName: string, topicName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise; listByTopic(resourceGroupName: string, namespaceName: string, topicName: string, callback: ServiceCallback): void; - listByTopic(resourceGroupName: string, namespaceName: string, topicName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByTopic(resourceGroupName: string, namespaceName: string, topicName: string, options: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** @@ -5029,6 +5077,14 @@ export interface Rules { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -5038,7 +5094,7 @@ export interface Rules { * * @reject {Error|ServiceError} - The error object. */ - listBySubscriptionsWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listBySubscriptionsWithHttpOperationResponse(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise>; /** * List all the rules within given topic-subscription @@ -5054,6 +5110,14 @@ export interface Rules { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -5079,9 +5143,9 @@ export interface Rules { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listBySubscriptions(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listBySubscriptions(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, options?: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }): Promise; listBySubscriptions(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, callback: ServiceCallback): void; - listBySubscriptions(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listBySubscriptions(resourceGroupName: string, namespaceName: string, topicName: string, subscriptionName: string, options: { skip? : number, top? : number, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** diff --git a/lib/services/serviceBusManagement2/lib/operations/queues.js b/lib/services/serviceBusManagement2/lib/operations/queues.js index 1578d3f68b..f84f61d7fa 100644 --- a/lib/services/serviceBusManagement2/lib/operations/queues.js +++ b/lib/services/serviceBusManagement2/lib/operations/queues.js @@ -25,6 +25,14 @@ const moment = require('moment'); * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -51,6 +59,8 @@ function _listByNamespace(resourceGroupName, namespaceName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let skip = (options && options.skip !== undefined) ? options.skip : undefined; + let top = (options && options.top !== undefined) ? options.top : undefined; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -85,6 +95,32 @@ function _listByNamespace(resourceGroupName, namespaceName, options, callback) { if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } + if (skip !== null && skip !== undefined && typeof skip !== 'number') { + throw new Error('skip must be of type number.'); + } + if (skip !== null && skip !== undefined) { + if (skip > 1000) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (skip < 0) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMinimum": 0'); + } + } + if (top !== null && top !== undefined && typeof top !== 'number') { + throw new Error('top must be of type number.'); + } + if (top !== null && top !== undefined) { + if (top > 1000) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (top < 1) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMinimum": 1'); + } + } if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { throw new Error('this.client.acceptLanguage must be of type string.'); } @@ -100,6 +136,12 @@ function _listByNamespace(resourceGroupName, namespaceName, options, callback) { requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + if (skip !== null && skip !== undefined) { + queryParameters.push('$skip=' + encodeURIComponent(skip.toString())); + } + if (top !== null && top !== undefined) { + queryParameters.push('$top=' + encodeURIComponent(top.toString())); + } if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2250,6 +2292,14 @@ class Queues { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -2283,6 +2333,14 @@ class Queues { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * diff --git a/lib/services/serviceBusManagement2/lib/operations/rules.js b/lib/services/serviceBusManagement2/lib/operations/rules.js index 56fb43b4f2..f85e6af08b 100644 --- a/lib/services/serviceBusManagement2/lib/operations/rules.js +++ b/lib/services/serviceBusManagement2/lib/operations/rules.js @@ -28,6 +28,14 @@ const WebResource = msRest.WebResource; * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -54,6 +62,8 @@ function _listBySubscriptions(resourceGroupName, namespaceName, topicName, subsc if (!callback) { throw new Error('callback cannot be null.'); } + let skip = (options && options.skip !== undefined) ? options.skip : undefined; + let top = (options && options.top !== undefined) ? options.top : undefined; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -110,6 +120,32 @@ function _listBySubscriptions(resourceGroupName, namespaceName, topicName, subsc if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } + if (skip !== null && skip !== undefined && typeof skip !== 'number') { + throw new Error('skip must be of type number.'); + } + if (skip !== null && skip !== undefined) { + if (skip > 1000) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (skip < 0) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMinimum": 0'); + } + } + if (top !== null && top !== undefined && typeof top !== 'number') { + throw new Error('top must be of type number.'); + } + if (top !== null && top !== undefined) { + if (top > 1000) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (top < 1) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMinimum": 1'); + } + } if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { throw new Error('this.client.acceptLanguage must be of type string.'); } @@ -127,6 +163,12 @@ function _listBySubscriptions(resourceGroupName, namespaceName, topicName, subsc requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + if (skip !== null && skip !== undefined) { + queryParameters.push('$skip=' + encodeURIComponent(skip.toString())); + } + if (top !== null && top !== undefined) { + queryParameters.push('$top=' + encodeURIComponent(top.toString())); + } if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -1057,6 +1099,14 @@ class Rules { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -1094,6 +1144,14 @@ class Rules { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * diff --git a/lib/services/serviceBusManagement2/lib/operations/subscriptions.js b/lib/services/serviceBusManagement2/lib/operations/subscriptions.js index 8e3e5bdf79..fa22c021c7 100644 --- a/lib/services/serviceBusManagement2/lib/operations/subscriptions.js +++ b/lib/services/serviceBusManagement2/lib/operations/subscriptions.js @@ -27,6 +27,14 @@ const moment = require('moment'); * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -54,6 +62,8 @@ function _listByTopic(resourceGroupName, namespaceName, topicName, options, call if (!callback) { throw new Error('callback cannot be null.'); } + let skip = (options && options.skip !== undefined) ? options.skip : undefined; + let top = (options && options.top !== undefined) ? options.top : undefined; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -97,6 +107,32 @@ function _listByTopic(resourceGroupName, namespaceName, topicName, options, call if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } + if (skip !== null && skip !== undefined && typeof skip !== 'number') { + throw new Error('skip must be of type number.'); + } + if (skip !== null && skip !== undefined) { + if (skip > 1000) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (skip < 0) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMinimum": 0'); + } + } + if (top !== null && top !== undefined && typeof top !== 'number') { + throw new Error('top must be of type number.'); + } + if (top !== null && top !== undefined) { + if (top > 1000) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (top < 1) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMinimum": 1'); + } + } if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { throw new Error('this.client.acceptLanguage must be of type string.'); } @@ -113,6 +149,12 @@ function _listByTopic(resourceGroupName, namespaceName, topicName, options, call requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + if (skip !== null && skip !== undefined) { + queryParameters.push('$skip=' + encodeURIComponent(skip.toString())); + } + if (top !== null && top !== undefined) { + queryParameters.push('$top=' + encodeURIComponent(top.toString())); + } if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -981,6 +1023,14 @@ class Subscriptions { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -1016,6 +1066,14 @@ class Subscriptions { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * diff --git a/lib/services/serviceBusManagement2/lib/operations/topics.js b/lib/services/serviceBusManagement2/lib/operations/topics.js index aa1d3762b9..8bd778266e 100644 --- a/lib/services/serviceBusManagement2/lib/operations/topics.js +++ b/lib/services/serviceBusManagement2/lib/operations/topics.js @@ -25,6 +25,14 @@ const moment = require('moment'); * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -51,6 +59,8 @@ function _listByNamespace(resourceGroupName, namespaceName, options, callback) { if (!callback) { throw new Error('callback cannot be null.'); } + let skip = (options && options.skip !== undefined) ? options.skip : undefined; + let top = (options && options.top !== undefined) ? options.top : undefined; // Validate try { if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { @@ -85,6 +95,32 @@ function _listByNamespace(resourceGroupName, namespaceName, options, callback) { if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); } + if (skip !== null && skip !== undefined && typeof skip !== 'number') { + throw new Error('skip must be of type number.'); + } + if (skip !== null && skip !== undefined) { + if (skip > 1000) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (skip < 0) + { + throw new Error('"skip" should satisfy the constraint - "InclusiveMinimum": 0'); + } + } + if (top !== null && top !== undefined && typeof top !== 'number') { + throw new Error('top must be of type number.'); + } + if (top !== null && top !== undefined) { + if (top > 1000) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMaximum": 1000'); + } + if (top < 1) + { + throw new Error('"top" should satisfy the constraint - "InclusiveMinimum": 1'); + } + } if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { throw new Error('this.client.acceptLanguage must be of type string.'); } @@ -100,6 +136,12 @@ function _listByNamespace(resourceGroupName, namespaceName, options, callback) { requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); let queryParameters = []; queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); + if (skip !== null && skip !== undefined) { + queryParameters.push('$skip=' + encodeURIComponent(skip.toString())); + } + if (top !== null && top !== undefined) { + queryParameters.push('$top=' + encodeURIComponent(top.toString())); + } if (queryParameters.length > 0) { requestUrl += '?' + queryParameters.join('&'); } @@ -2232,6 +2274,14 @@ class Topics { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -2265,6 +2315,14 @@ class Topics { * * @param {object} [options] Optional Parameters. * + * @param {number} [options.skip] Skip is only used if a previous operation + * returned a partial result. If a previous response contains a nextLink + * element, the value of the nextLink element will include a skip parameter + * that specifies a starting point to use for subsequent calls. + * + * @param {number} [options.top] May be used to limit the number of results to + * the most recent N usageDetails. + * * @param {object} [options.customHeaders] Headers that will be added to the * request *