@azure/arm-vmwarecloudsimple 3.1.1-alpha.20250717.1 → 3.1.1-alpha.20250730.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/lroImpl.js +11 -3
- package/dist/browser/lroImpl.js.map +1 -1
- package/dist/browser/operations/customizationPolicies.js +23 -40
- package/dist/browser/operations/customizationPolicies.js.map +1 -1
- package/dist/browser/operations/dedicatedCloudNodes.js +56 -85
- package/dist/browser/operations/dedicatedCloudNodes.js.map +1 -1
- package/dist/browser/operations/dedicatedCloudServices.js +56 -85
- package/dist/browser/operations/dedicatedCloudServices.js.map +1 -1
- package/dist/browser/operations/operations.js +23 -40
- package/dist/browser/operations/operations.js.map +1 -1
- package/dist/browser/operations/privateClouds.js +23 -40
- package/dist/browser/operations/privateClouds.js.map +1 -1
- package/dist/browser/operations/resourcePools.js +23 -40
- package/dist/browser/operations/resourcePools.js.map +1 -1
- package/dist/browser/operations/skusAvailability.js +23 -40
- package/dist/browser/operations/skusAvailability.js.map +1 -1
- package/dist/browser/operations/usages.js +23 -40
- package/dist/browser/operations/usages.js.map +1 -1
- package/dist/browser/operations/virtualMachineTemplates.js +23 -40
- package/dist/browser/operations/virtualMachineTemplates.js.map +1 -1
- package/dist/browser/operations/virtualMachines.js +100 -109
- package/dist/browser/operations/virtualMachines.js.map +1 -1
- package/dist/browser/operations/virtualNetworks.js +23 -40
- package/dist/browser/operations/virtualNetworks.js.map +1 -1
- package/dist/browser/pagingHelper.js +2 -4
- package/dist/browser/pagingHelper.js.map +1 -1
- package/dist/browser/vMwareCloudSimple.js +24 -5
- package/dist/browser/vMwareCloudSimple.js.map +1 -1
- package/dist/commonjs/lroImpl.js +11 -3
- package/dist/commonjs/lroImpl.js.map +1 -1
- package/dist/commonjs/operations/customizationPolicies.js +23 -39
- package/dist/commonjs/operations/customizationPolicies.js.map +1 -1
- package/dist/commonjs/operations/dedicatedCloudNodes.js +56 -84
- package/dist/commonjs/operations/dedicatedCloudNodes.js.map +1 -1
- package/dist/commonjs/operations/dedicatedCloudServices.js +56 -84
- package/dist/commonjs/operations/dedicatedCloudServices.js.map +1 -1
- package/dist/commonjs/operations/operations.js +23 -39
- package/dist/commonjs/operations/operations.js.map +1 -1
- package/dist/commonjs/operations/privateClouds.js +23 -39
- package/dist/commonjs/operations/privateClouds.js.map +1 -1
- package/dist/commonjs/operations/resourcePools.js +23 -39
- package/dist/commonjs/operations/resourcePools.js.map +1 -1
- package/dist/commonjs/operations/skusAvailability.js +23 -39
- package/dist/commonjs/operations/skusAvailability.js.map +1 -1
- package/dist/commonjs/operations/usages.js +23 -39
- package/dist/commonjs/operations/usages.js.map +1 -1
- package/dist/commonjs/operations/virtualMachineTemplates.js +23 -39
- package/dist/commonjs/operations/virtualMachineTemplates.js.map +1 -1
- package/dist/commonjs/operations/virtualMachines.js +100 -108
- package/dist/commonjs/operations/virtualMachines.js.map +1 -1
- package/dist/commonjs/operations/virtualNetworks.js +23 -39
- package/dist/commonjs/operations/virtualNetworks.js.map +1 -1
- package/dist/commonjs/pagingHelper.js +2 -4
- package/dist/commonjs/pagingHelper.js.map +1 -1
- package/dist/commonjs/tsdoc-metadata.json +11 -11
- package/dist/commonjs/vMwareCloudSimple.js +24 -5
- package/dist/commonjs/vMwareCloudSimple.js.map +1 -1
- package/dist/esm/lroImpl.js +11 -3
- package/dist/esm/lroImpl.js.map +1 -1
- package/dist/esm/operations/customizationPolicies.js +23 -40
- package/dist/esm/operations/customizationPolicies.js.map +1 -1
- package/dist/esm/operations/dedicatedCloudNodes.js +56 -85
- package/dist/esm/operations/dedicatedCloudNodes.js.map +1 -1
- package/dist/esm/operations/dedicatedCloudServices.js +56 -85
- package/dist/esm/operations/dedicatedCloudServices.js.map +1 -1
- package/dist/esm/operations/operations.js +23 -40
- package/dist/esm/operations/operations.js.map +1 -1
- package/dist/esm/operations/privateClouds.js +23 -40
- package/dist/esm/operations/privateClouds.js.map +1 -1
- package/dist/esm/operations/resourcePools.js +23 -40
- package/dist/esm/operations/resourcePools.js.map +1 -1
- package/dist/esm/operations/skusAvailability.js +23 -40
- package/dist/esm/operations/skusAvailability.js.map +1 -1
- package/dist/esm/operations/usages.js +23 -40
- package/dist/esm/operations/usages.js.map +1 -1
- package/dist/esm/operations/virtualMachineTemplates.js +23 -40
- package/dist/esm/operations/virtualMachineTemplates.js.map +1 -1
- package/dist/esm/operations/virtualMachines.js +100 -109
- package/dist/esm/operations/virtualMachines.js.map +1 -1
- package/dist/esm/operations/virtualNetworks.js +23 -40
- package/dist/esm/operations/virtualNetworks.js.map +1 -1
- package/dist/esm/pagingHelper.js +2 -4
- package/dist/esm/pagingHelper.js.map +1 -1
- package/dist/esm/vMwareCloudSimple.js +24 -5
- package/dist/esm/vMwareCloudSimple.js.map +1 -1
- package/dist/react-native/lroImpl.js +11 -3
- package/dist/react-native/lroImpl.js.map +1 -1
- package/dist/react-native/operations/customizationPolicies.js +23 -40
- package/dist/react-native/operations/customizationPolicies.js.map +1 -1
- package/dist/react-native/operations/dedicatedCloudNodes.js +56 -85
- package/dist/react-native/operations/dedicatedCloudNodes.js.map +1 -1
- package/dist/react-native/operations/dedicatedCloudServices.js +56 -85
- package/dist/react-native/operations/dedicatedCloudServices.js.map +1 -1
- package/dist/react-native/operations/operations.js +23 -40
- package/dist/react-native/operations/operations.js.map +1 -1
- package/dist/react-native/operations/privateClouds.js +23 -40
- package/dist/react-native/operations/privateClouds.js.map +1 -1
- package/dist/react-native/operations/resourcePools.js +23 -40
- package/dist/react-native/operations/resourcePools.js.map +1 -1
- package/dist/react-native/operations/skusAvailability.js +23 -40
- package/dist/react-native/operations/skusAvailability.js.map +1 -1
- package/dist/react-native/operations/usages.js +23 -40
- package/dist/react-native/operations/usages.js.map +1 -1
- package/dist/react-native/operations/virtualMachineTemplates.js +23 -40
- package/dist/react-native/operations/virtualMachineTemplates.js.map +1 -1
- package/dist/react-native/operations/virtualMachines.js +100 -109
- package/dist/react-native/operations/virtualMachines.js.map +1 -1
- package/dist/react-native/operations/virtualNetworks.js +23 -40
- package/dist/react-native/operations/virtualNetworks.js.map +1 -1
- package/dist/react-native/pagingHelper.js +2 -4
- package/dist/react-native/pagingHelper.js.map +1 -1
- package/dist/react-native/vMwareCloudSimple.js +24 -5
- package/dist/react-native/vMwareCloudSimple.js.map +1 -1
- package/package.json +2 -2
- package/review/arm-vmwarecloudsimple-node.api.md +1104 -1104
|
@@ -16,6 +16,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
|
|
|
16
16
|
/// <reference lib="esnext.asynciterable" />
|
|
17
17
|
/** Class containing SkusAvailability operations. */
|
|
18
18
|
class SkusAvailabilityImpl {
|
|
19
|
+
client;
|
|
19
20
|
/**
|
|
20
21
|
* Initialize a new instance of the class SkusAvailability class.
|
|
21
22
|
* @param client Reference to the service client
|
|
@@ -38,52 +39,35 @@ class SkusAvailabilityImpl {
|
|
|
38
39
|
return this;
|
|
39
40
|
},
|
|
40
41
|
byPage: (settings) => {
|
|
41
|
-
if (settings
|
|
42
|
+
if (settings?.maxPageSize) {
|
|
42
43
|
throw new Error("maxPageSize is not supported by this operation.");
|
|
43
44
|
}
|
|
44
45
|
return this.listPagingPage(regionId, options, settings);
|
|
45
46
|
}
|
|
46
47
|
};
|
|
47
48
|
}
|
|
48
|
-
listPagingPage(regionId, options, settings) {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
});
|
|
49
|
+
async *listPagingPage(regionId, options, settings) {
|
|
50
|
+
let result;
|
|
51
|
+
let continuationToken = settings?.continuationToken;
|
|
52
|
+
if (!continuationToken) {
|
|
53
|
+
result = await this._list(regionId, options);
|
|
54
|
+
let page = result.value || [];
|
|
55
|
+
continuationToken = result.nextLink;
|
|
56
|
+
(0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
|
|
57
|
+
yield page;
|
|
58
|
+
}
|
|
59
|
+
while (continuationToken) {
|
|
60
|
+
result = await this._listNext(regionId, continuationToken, options);
|
|
61
|
+
continuationToken = result.nextLink;
|
|
62
|
+
let page = result.value || [];
|
|
63
|
+
(0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
|
|
64
|
+
yield page;
|
|
65
|
+
}
|
|
67
66
|
}
|
|
68
|
-
listPagingAll(regionId, options) {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
for (var _d = true, _e = tslib_1.__asyncValues(this.listPagingPage(regionId, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
|
|
73
|
-
_c = _f.value;
|
|
74
|
-
_d = false;
|
|
75
|
-
const page = _c;
|
|
76
|
-
yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
80
|
-
finally {
|
|
81
|
-
try {
|
|
82
|
-
if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
|
|
83
|
-
}
|
|
84
|
-
finally { if (e_1) throw e_1.error; }
|
|
85
|
-
}
|
|
86
|
-
});
|
|
67
|
+
async *listPagingAll(regionId, options) {
|
|
68
|
+
for await (const page of this.listPagingPage(regionId, options)) {
|
|
69
|
+
yield* page;
|
|
70
|
+
}
|
|
87
71
|
}
|
|
88
72
|
/**
|
|
89
73
|
* Returns list of available resources in region
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skusAvailability.js","sourceRoot":"","sources":["../../../src/operations/skusAvailability.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAUtD,4C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AAiB,GAA6B;IAClD,IAAI,EACF,2GAA2G;IAC7G,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,2BAA2B;SAChD;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,SAAS;SAC9B;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,EAAE,UAAU,CAAC,KAAK,CAAC;IAC1D,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;KACpB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC;AACF,MAAM,qBAAqB,GAA6B;IACtD,IAAI,EAAE,YAAY;IAClB,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,2BAA2B;SAChD;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,SAAS;SAC9B;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,QAAQ;KACpB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport { SkusAvailability } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport { VMwareCloudSimple } from \"../vMwareCloudSimple.js\";\nimport {\n SkuAvailability,\n SkusAvailabilityListNextOptionalParams,\n SkusAvailabilityListOptionalParams,\n SkusAvailabilityListResponse,\n SkusAvailabilityListNextResponse\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing SkusAvailability operations. */\nexport class SkusAvailabilityImpl implements SkusAvailability {\n private readonly client: VMwareCloudSimple;\n\n /**\n * Initialize a new instance of the class SkusAvailability class.\n * @param client Reference to the service client\n */\n constructor(client: VMwareCloudSimple) {\n this.client = client;\n }\n\n /**\n * Returns list of available resources in region\n * @param regionId The region Id (westus, eastus)\n * @param options The options parameters.\n */\n public list(\n regionId: string,\n options?: SkusAvailabilityListOptionalParams\n ): PagedAsyncIterableIterator<SkuAvailability> {\n const iter = this.listPagingAll(regionId, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listPagingPage(regionId, options, settings);\n }\n };\n }\n\n private async *listPagingPage(\n regionId: string,\n options?: SkusAvailabilityListOptionalParams,\n settings?: PageSettings\n ): AsyncIterableIterator<SkuAvailability[]> {\n let result: SkusAvailabilityListResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._list(regionId, options);\n let page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listNext(regionId, continuationToken, options);\n continuationToken = result.nextLink;\n let page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listPagingAll(\n regionId: string,\n options?: SkusAvailabilityListOptionalParams\n ): AsyncIterableIterator<SkuAvailability> {\n for await (const page of this.listPagingPage(regionId, options)) {\n yield* page;\n }\n }\n\n /**\n * Returns list of available resources in region\n * @param regionId The region Id (westus, eastus)\n * @param options The options parameters.\n */\n private _list(\n regionId: string,\n options?: SkusAvailabilityListOptionalParams\n ): Promise<SkusAvailabilityListResponse> {\n return this.client.sendOperationRequest(\n { regionId, options },\n listOperationSpec\n );\n }\n\n /**\n * ListNext\n * @param regionId The region Id (westus, eastus)\n * @param nextLink The nextLink from the previous successful call to the List method.\n * @param options The options parameters.\n */\n private _listNext(\n regionId: string,\n nextLink: string,\n options?: SkusAvailabilityListNextOptionalParams\n ): Promise<SkusAvailabilityListNextResponse> {\n return this.client.sendOperationRequest(\n { regionId, nextLink, options },\n listNextOperationSpec\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listOperationSpec: coreClient.OperationSpec = {\n path:\n \"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/locations/{regionId}/availabilities\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SkuAvailabilityListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n queryParameters: [Parameters.apiVersion, Parameters.skuId],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\nconst listNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SkuAvailabilityListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.nextLink\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\n"]}
|
|
@@ -16,6 +16,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
|
|
|
16
16
|
/// <reference lib="esnext.asynciterable" />
|
|
17
17
|
/** Class containing Usages operations. */
|
|
18
18
|
class UsagesImpl {
|
|
19
|
+
client;
|
|
19
20
|
/**
|
|
20
21
|
* Initialize a new instance of the class Usages class.
|
|
21
22
|
* @param client Reference to the service client
|
|
@@ -38,52 +39,35 @@ class UsagesImpl {
|
|
|
38
39
|
return this;
|
|
39
40
|
},
|
|
40
41
|
byPage: (settings) => {
|
|
41
|
-
if (settings
|
|
42
|
+
if (settings?.maxPageSize) {
|
|
42
43
|
throw new Error("maxPageSize is not supported by this operation.");
|
|
43
44
|
}
|
|
44
45
|
return this.listPagingPage(regionId, options, settings);
|
|
45
46
|
}
|
|
46
47
|
};
|
|
47
48
|
}
|
|
48
|
-
listPagingPage(regionId, options, settings) {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
});
|
|
49
|
+
async *listPagingPage(regionId, options, settings) {
|
|
50
|
+
let result;
|
|
51
|
+
let continuationToken = settings?.continuationToken;
|
|
52
|
+
if (!continuationToken) {
|
|
53
|
+
result = await this._list(regionId, options);
|
|
54
|
+
let page = result.value || [];
|
|
55
|
+
continuationToken = result.nextLink;
|
|
56
|
+
(0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
|
|
57
|
+
yield page;
|
|
58
|
+
}
|
|
59
|
+
while (continuationToken) {
|
|
60
|
+
result = await this._listNext(regionId, continuationToken, options);
|
|
61
|
+
continuationToken = result.nextLink;
|
|
62
|
+
let page = result.value || [];
|
|
63
|
+
(0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
|
|
64
|
+
yield page;
|
|
65
|
+
}
|
|
67
66
|
}
|
|
68
|
-
listPagingAll(regionId, options) {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
for (var _d = true, _e = tslib_1.__asyncValues(this.listPagingPage(regionId, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
|
|
73
|
-
_c = _f.value;
|
|
74
|
-
_d = false;
|
|
75
|
-
const page = _c;
|
|
76
|
-
yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
80
|
-
finally {
|
|
81
|
-
try {
|
|
82
|
-
if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
|
|
83
|
-
}
|
|
84
|
-
finally { if (e_1) throw e_1.error; }
|
|
85
|
-
}
|
|
86
|
-
});
|
|
67
|
+
async *listPagingAll(regionId, options) {
|
|
68
|
+
for await (const page of this.listPagingPage(regionId, options)) {
|
|
69
|
+
yield* page;
|
|
70
|
+
}
|
|
87
71
|
}
|
|
88
72
|
/**
|
|
89
73
|
* Returns list of usage in region
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"usages.js","sourceRoot":"","sources":["../../../src/operations/usages.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAUtD,4CAA4C;AAC5C,0CAA0C;AAC1C,MAAa,UAAU;
|
|
1
|
+
{"version":3,"file":"usages.js","sourceRoot":"","sources":["../../../src/operations/usages.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAUtD,4CAA4C;AAC5C,0CAA0C;AAC1C,MAAa,UAAU;IACJ,MAAM,CAAoB;IAE3C;;;OAGG;IACH,YAAY,MAAyB;QACnC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;OAIG;IACI,IAAI,CACT,QAAgB,EAChB,OAAkC;QAElC,MAAM,IAAI,GAAG,IAAI,CAAC,aAAa,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAC;QACnD,OAAO;YACL,IAAI;gBACF,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC;YACrB,CAAC;YACD,CAAC,M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;SACtC;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,SAAS;SAC9B;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,QAAQ;KACpB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport { Usages } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport { VMwareCloudSimple } from \"../vMwareCloudSimple.js\";\nimport {\n Usage,\n UsagesListNextOptionalParams,\n UsagesListOptionalParams,\n UsagesListResponse,\n UsagesListNextResponse\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing Usages operations. */\nexport class UsagesImpl implements Usages {\n private readonly client: VMwareCloudSimple;\n\n /**\n * Initialize a new instance of the class Usages class.\n * @param client Reference to the service client\n */\n constructor(client: VMwareCloudSimple) {\n this.client = client;\n }\n\n /**\n * Returns list of usage in region\n * @param regionId The region Id (westus, eastus)\n * @param options The options parameters.\n */\n public list(\n regionId: string,\n options?: UsagesListOptionalParams\n ): PagedAsyncIterableIterator<Usage> {\n const iter = this.listPagingAll(regionId, options);\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listPagingPage(regionId, options, settings);\n }\n };\n }\n\n private async *listPagingPage(\n regionId: string,\n options?: UsagesListOptionalParams,\n settings?: PageSettings\n ): AsyncIterableIterator<Usage[]> {\n let result: UsagesListResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._list(regionId, options);\n let page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listNext(regionId, continuationToken, options);\n continuationToken = result.nextLink;\n let page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listPagingAll(\n regionId: string,\n options?: UsagesListOptionalParams\n ): AsyncIterableIterator<Usage> {\n for await (const page of this.listPagingPage(regionId, options)) {\n yield* page;\n }\n }\n\n /**\n * Returns list of usage in region\n * @param regionId The region Id (westus, eastus)\n * @param options The options parameters.\n */\n private _list(\n regionId: string,\n options?: UsagesListOptionalParams\n ): Promise<UsagesListResponse> {\n return this.client.sendOperationRequest(\n { regionId, options },\n listOperationSpec\n );\n }\n\n /**\n * ListNext\n * @param regionId The region Id (westus, eastus)\n * @param nextLink The nextLink from the previous successful call to the List method.\n * @param options The options parameters.\n */\n private _listNext(\n regionId: string,\n nextLink: string,\n options?: UsagesListNextOptionalParams\n ): Promise<UsagesListNextResponse> {\n return this.client.sendOperationRequest(\n { regionId, nextLink, options },\n listNextOperationSpec\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listOperationSpec: coreClient.OperationSpec = {\n path:\n \"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/locations/{regionId}/usages\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.UsageListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n queryParameters: [Parameters.apiVersion, Parameters.filter],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\nconst listNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.UsageListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.nextLink\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\n"]}
|
|
@@ -16,6 +16,7 @@ const Parameters = tslib_1.__importStar(require("../models/parameters.js"));
|
|
|
16
16
|
/// <reference lib="esnext.asynciterable" />
|
|
17
17
|
/** Class containing VirtualMachineTemplates operations. */
|
|
18
18
|
class VirtualMachineTemplatesImpl {
|
|
19
|
+
client;
|
|
19
20
|
/**
|
|
20
21
|
* Initialize a new instance of the class VirtualMachineTemplates class.
|
|
21
22
|
* @param client Reference to the service client
|
|
@@ -40,52 +41,35 @@ class VirtualMachineTemplatesImpl {
|
|
|
40
41
|
return this;
|
|
41
42
|
},
|
|
42
43
|
byPage: (settings) => {
|
|
43
|
-
if (settings
|
|
44
|
+
if (settings?.maxPageSize) {
|
|
44
45
|
throw new Error("maxPageSize is not supported by this operation.");
|
|
45
46
|
}
|
|
46
47
|
return this.listPagingPage(pcName, regionId, resourcePoolName, options, settings);
|
|
47
48
|
}
|
|
48
49
|
};
|
|
49
50
|
}
|
|
50
|
-
listPagingPage(pcName, regionId, resourcePoolName, options, settings) {
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}
|
|
68
|
-
});
|
|
51
|
+
async *listPagingPage(pcName, regionId, resourcePoolName, options, settings) {
|
|
52
|
+
let result;
|
|
53
|
+
let continuationToken = settings?.continuationToken;
|
|
54
|
+
if (!continuationToken) {
|
|
55
|
+
result = await this._list(pcName, regionId, resourcePoolName, options);
|
|
56
|
+
let page = result.value || [];
|
|
57
|
+
continuationToken = result.nextLink;
|
|
58
|
+
(0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
|
|
59
|
+
yield page;
|
|
60
|
+
}
|
|
61
|
+
while (continuationToken) {
|
|
62
|
+
result = await this._listNext(pcName, regionId, continuationToken, options);
|
|
63
|
+
continuationToken = result.nextLink;
|
|
64
|
+
let page = result.value || [];
|
|
65
|
+
(0, pagingHelper_js_1.setContinuationToken)(page, continuationToken);
|
|
66
|
+
yield page;
|
|
67
|
+
}
|
|
69
68
|
}
|
|
70
|
-
listPagingAll(pcName, regionId, resourcePoolName, options) {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
for (var _d = true, _e = tslib_1.__asyncValues(this.listPagingPage(pcName, regionId, resourcePoolName, options)), _f; _f = yield tslib_1.__await(_e.next()), _a = _f.done, !_a; _d = true) {
|
|
75
|
-
_c = _f.value;
|
|
76
|
-
_d = false;
|
|
77
|
-
const page = _c;
|
|
78
|
-
yield tslib_1.__await(yield* tslib_1.__asyncDelegator(tslib_1.__asyncValues(page)));
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
82
|
-
finally {
|
|
83
|
-
try {
|
|
84
|
-
if (!_d && !_a && (_b = _e.return)) yield tslib_1.__await(_b.call(_e));
|
|
85
|
-
}
|
|
86
|
-
finally { if (e_1) throw e_1.error; }
|
|
87
|
-
}
|
|
88
|
-
});
|
|
69
|
+
async *listPagingAll(pcName, regionId, resourcePoolName, options) {
|
|
70
|
+
for await (const page of this.listPagingPage(pcName, regionId, resourcePoolName, options)) {
|
|
71
|
+
yield* page;
|
|
72
|
+
}
|
|
89
73
|
}
|
|
90
74
|
/**
|
|
91
75
|
* Returns list of virtual machine templates in region for private cloud
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"virtualMachineTemplates.js","sourceRoot":"","sources":["../../../src/operations/virtualM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AS;SAC9B;KACF;IACD,eAAe,EAAE,CAAC,UAAU,CAAC,UAAU,CAAC;IACxC,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,MAAM;QACjB,UAAU,CAAC,0BAA0B;KACtC;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC;AACF,MAAM,qBAAqB,GAA6B;IACtD,IAAI,EAAE,YAAY;IAClB,UAAU,EAAE,KAAK;IACjB,SAAS,EAAE;QACT,GAAG,EAAE;YACH,UAAU,EAAE,OAAO,CAAC,kCAAkC;SACvD;QACD,OAAO,EAAE;YACP,UAAU,EAAE,OAAO,CAAC,SAAS;SAC9B;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,MAAM;KAClB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport { VirtualMachineTemplates } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport { VMwareCloudSimple } from \"../vMwareCloudSimple.js\";\nimport {\n VirtualMachineTemplate,\n VirtualMachineTemplatesListNextOptionalParams,\n VirtualMachineTemplatesListOptionalParams,\n VirtualMachineTemplatesListResponse,\n VirtualMachineTemplatesGetOptionalParams,\n VirtualMachineTemplatesGetResponse,\n VirtualMachineTemplatesListNextResponse\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing VirtualMachineTemplates operations. */\nexport class VirtualMachineTemplatesImpl implements VirtualMachineTemplates {\n private readonly client: VMwareCloudSimple;\n\n /**\n * Initialize a new instance of the class VirtualMachineTemplates class.\n * @param client Reference to the service client\n */\n constructor(client: VMwareCloudSimple) {\n this.client = client;\n }\n\n /**\n * Returns list of virtual machine templates in region for private cloud\n * @param pcName The private cloud name\n * @param regionId The region Id (westus, eastus)\n * @param resourcePoolName Resource pool used to derive vSphere cluster which contains VM templates\n * @param options The options parameters.\n */\n public list(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams\n ): PagedAsyncIterableIterator<VirtualMachineTemplate> {\n const iter = this.listPagingAll(\n pcName,\n regionId,\n resourcePoolName,\n options\n );\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listPagingPage(\n pcName,\n regionId,\n resourcePoolName,\n options,\n settings\n );\n }\n };\n }\n\n private async *listPagingPage(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams,\n settings?: PageSettings\n ): AsyncIterableIterator<VirtualMachineTemplate[]> {\n let result: VirtualMachineTemplatesListResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._list(pcName, regionId, resourcePoolName, options);\n let page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listNext(\n pcName,\n regionId,\n continuationToken,\n options\n );\n continuationToken = result.nextLink;\n let page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listPagingAll(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams\n ): AsyncIterableIterator<VirtualMachineTemplate> {\n for await (const page of this.listPagingPage(\n pcName,\n regionId,\n resourcePoolName,\n options\n )) {\n yield* page;\n }\n }\n\n /**\n * Returns list of virtual machine templates in region for private cloud\n * @param pcName The private cloud name\n * @param regionId The region Id (westus, eastus)\n * @param resourcePoolName Resource pool used to derive vSphere cluster which contains VM templates\n * @param options The options parameters.\n */\n private _list(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams\n ): Promise<VirtualMachineTemplatesListResponse> {\n return this.client.sendOperationRequest(\n { pcName, regionId, resourcePoolName, options },\n listOperationSpec\n );\n }\n\n /**\n * Returns virtual machine templates by its name\n * @param regionId The region Id (westus, eastus)\n * @param pcName The private cloud name\n * @param virtualMachineTemplateName virtual machine template id (vsphereId)\n * @param options The options parameters.\n */\n get(\n regionId: string,\n pcName: string,\n virtualMachineTemplateName: string,\n options?: VirtualMachineTemplatesGetOptionalParams\n ): Promise<VirtualMachineTemplatesGetResponse> {\n return this.client.sendOperationRequest(\n { regionId, pcName, virtualMachineTemplateName, options },\n getOperationSpec\n );\n }\n\n /**\n * ListNext\n * @param pcName The private cloud name\n * @param regionId The region Id (westus, eastus)\n * @param nextLink The nextLink from the previous successful call to the List method.\n * @param options The options parameters.\n */\n private _listNext(\n pcName: string,\n regionId: string,\n nextLink: string,\n options?: VirtualMachineTemplatesListNextOptionalParams\n ): Promise<VirtualMachineTemplatesListNextResponse> {\n return this.client.sendOperationRequest(\n { pcName, regionId, nextLink, options },\n listNextOperationSpec\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listOperationSpec: coreClient.OperationSpec = {\n path:\n \"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/locations/{regionId}/privateClouds/{pcName}/virtualMachineTemplates\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.VirtualMachineTemplateListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n queryParameters: [Parameters.apiVersion, Parameters.resourcePoolName1],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.pcName\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\nconst getOperationSpec: coreClient.OperationSpec = {\n path:\n \"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/locations/{regionId}/privateClouds/{pcName}/virtualMachineTemplates/{virtualMachineTemplateName}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.VirtualMachineTemplate\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.pcName,\n Parameters.virtualMachineTemplateName\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\nconst listNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.VirtualMachineTemplateListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.nextLink,\n Parameters.pcName\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\n"]}
|
|
1
|
+
{"version":3,"file":"virtualMachineTemplates.js","sourceRoot":"","sources":["../../../src/operations/virtualMachineTemplates.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG;;;;AAGH,wDAA0D;AAE1D,uEAAiD;AACjD,sEAAgD;AAChD,4EAAsD;AAYtD,4CAA4C;AAC5C,2DAA2D;AAC3D,MAAa,2BAA2B;IACrB,MAAM,CAAoB;IAE3C;;;OAGG;IACH,YAAY,MAAyB;QACnC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;IAED;;;;;;OAMG;IACI,IAAI,CACT,MAAc,EACd,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SAC9B;KACF;IACD,aAAa,EAAE;QACb,UAAU,CAAC,KAAK;QAChB,UAAU,CAAC,cAAc;QACzB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,QAAQ;QACnB,UAAU,CAAC,MAAM;KAClB;IACD,gBAAgB,EAAE,CAAC,UAAU,CAAC,MAAM,CAAC;IACrC,UAAU;CACX,CAAC","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport { PagedAsyncIterableIterator, PageSettings } from \"@azure/core-paging\";\nimport { setContinuationToken } from \"../pagingHelper.js\";\nimport { VirtualMachineTemplates } from \"../operationsInterfaces/index.js\";\nimport * as coreClient from \"@azure/core-client\";\nimport * as Mappers from \"../models/mappers.js\";\nimport * as Parameters from \"../models/parameters.js\";\nimport { VMwareCloudSimple } from \"../vMwareCloudSimple.js\";\nimport {\n VirtualMachineTemplate,\n VirtualMachineTemplatesListNextOptionalParams,\n VirtualMachineTemplatesListOptionalParams,\n VirtualMachineTemplatesListResponse,\n VirtualMachineTemplatesGetOptionalParams,\n VirtualMachineTemplatesGetResponse,\n VirtualMachineTemplatesListNextResponse\n} from \"../models/index.js\";\n\n/// <reference lib=\"esnext.asynciterable\" />\n/** Class containing VirtualMachineTemplates operations. */\nexport class VirtualMachineTemplatesImpl implements VirtualMachineTemplates {\n private readonly client: VMwareCloudSimple;\n\n /**\n * Initialize a new instance of the class VirtualMachineTemplates class.\n * @param client Reference to the service client\n */\n constructor(client: VMwareCloudSimple) {\n this.client = client;\n }\n\n /**\n * Returns list of virtual machine templates in region for private cloud\n * @param pcName The private cloud name\n * @param regionId The region Id (westus, eastus)\n * @param resourcePoolName Resource pool used to derive vSphere cluster which contains VM templates\n * @param options The options parameters.\n */\n public list(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams\n ): PagedAsyncIterableIterator<VirtualMachineTemplate> {\n const iter = this.listPagingAll(\n pcName,\n regionId,\n resourcePoolName,\n options\n );\n return {\n next() {\n return iter.next();\n },\n [Symbol.asyncIterator]() {\n return this;\n },\n byPage: (settings?: PageSettings) => {\n if (settings?.maxPageSize) {\n throw new Error(\"maxPageSize is not supported by this operation.\");\n }\n return this.listPagingPage(\n pcName,\n regionId,\n resourcePoolName,\n options,\n settings\n );\n }\n };\n }\n\n private async *listPagingPage(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams,\n settings?: PageSettings\n ): AsyncIterableIterator<VirtualMachineTemplate[]> {\n let result: VirtualMachineTemplatesListResponse;\n let continuationToken = settings?.continuationToken;\n if (!continuationToken) {\n result = await this._list(pcName, regionId, resourcePoolName, options);\n let page = result.value || [];\n continuationToken = result.nextLink;\n setContinuationToken(page, continuationToken);\n yield page;\n }\n while (continuationToken) {\n result = await this._listNext(\n pcName,\n regionId,\n continuationToken,\n options\n );\n continuationToken = result.nextLink;\n let page = result.value || [];\n setContinuationToken(page, continuationToken);\n yield page;\n }\n }\n\n private async *listPagingAll(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams\n ): AsyncIterableIterator<VirtualMachineTemplate> {\n for await (const page of this.listPagingPage(\n pcName,\n regionId,\n resourcePoolName,\n options\n )) {\n yield* page;\n }\n }\n\n /**\n * Returns list of virtual machine templates in region for private cloud\n * @param pcName The private cloud name\n * @param regionId The region Id (westus, eastus)\n * @param resourcePoolName Resource pool used to derive vSphere cluster which contains VM templates\n * @param options The options parameters.\n */\n private _list(\n pcName: string,\n regionId: string,\n resourcePoolName: string,\n options?: VirtualMachineTemplatesListOptionalParams\n ): Promise<VirtualMachineTemplatesListResponse> {\n return this.client.sendOperationRequest(\n { pcName, regionId, resourcePoolName, options },\n listOperationSpec\n );\n }\n\n /**\n * Returns virtual machine templates by its name\n * @param regionId The region Id (westus, eastus)\n * @param pcName The private cloud name\n * @param virtualMachineTemplateName virtual machine template id (vsphereId)\n * @param options The options parameters.\n */\n get(\n regionId: string,\n pcName: string,\n virtualMachineTemplateName: string,\n options?: VirtualMachineTemplatesGetOptionalParams\n ): Promise<VirtualMachineTemplatesGetResponse> {\n return this.client.sendOperationRequest(\n { regionId, pcName, virtualMachineTemplateName, options },\n getOperationSpec\n );\n }\n\n /**\n * ListNext\n * @param pcName The private cloud name\n * @param regionId The region Id (westus, eastus)\n * @param nextLink The nextLink from the previous successful call to the List method.\n * @param options The options parameters.\n */\n private _listNext(\n pcName: string,\n regionId: string,\n nextLink: string,\n options?: VirtualMachineTemplatesListNextOptionalParams\n ): Promise<VirtualMachineTemplatesListNextResponse> {\n return this.client.sendOperationRequest(\n { pcName, regionId, nextLink, options },\n listNextOperationSpec\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst listOperationSpec: coreClient.OperationSpec = {\n path:\n \"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/locations/{regionId}/privateClouds/{pcName}/virtualMachineTemplates\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.VirtualMachineTemplateListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n queryParameters: [Parameters.apiVersion, Parameters.resourcePoolName1],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.pcName\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\nconst getOperationSpec: coreClient.OperationSpec = {\n path:\n \"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/locations/{regionId}/privateClouds/{pcName}/virtualMachineTemplates/{virtualMachineTemplateName}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.VirtualMachineTemplate\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n queryParameters: [Parameters.apiVersion],\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.pcName,\n Parameters.virtualMachineTemplateName\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\nconst listNextOperationSpec: coreClient.OperationSpec = {\n path: \"{nextLink}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.VirtualMachineTemplateListResponse\n },\n default: {\n bodyMapper: Mappers.CsrpError\n }\n },\n urlParameters: [\n Parameters.$host,\n Parameters.subscriptionId,\n Parameters.regionId,\n Parameters.nextLink,\n Parameters.pcName\n ],\n headerParameters: [Parameters.accept],\n serializer\n};\n"]}
|