@azure/arm-vmwarecloudsimple 1.1.1 → 2.0.0
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/CHANGELOG.md +11 -0
- package/LICENSE +21 -0
- package/README.md +69 -80
- package/dist/index.js +5683 -0
- package/dist/index.js.map +1 -0
- package/dist/index.min.js +1 -0
- package/dist/index.min.js.map +1 -0
- package/dist-esm/src/index.d.ts +5 -0
- package/dist-esm/src/index.d.ts.map +1 -0
- package/dist-esm/src/index.js +12 -0
- package/dist-esm/src/index.js.map +1 -0
- package/dist-esm/src/lroImpl.d.ts +16 -0
- package/dist-esm/src/lroImpl.d.ts.map +1 -0
- package/dist-esm/src/lroImpl.js +29 -0
- package/dist-esm/src/lroImpl.js.map +1 -0
- package/dist-esm/src/models/index.d.ts +1328 -0
- package/dist-esm/src/models/index.d.ts.map +1 -0
- package/dist-esm/src/models/index.js +44 -0
- package/dist-esm/src/models/index.js.map +1 -0
- package/dist-esm/src/models/mappers.d.ts +59 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -0
- package/{esm → dist-esm/src}/models/mappers.js +1185 -834
- package/dist-esm/src/models/mappers.js.map +1 -0
- package/dist-esm/src/models/parameters.d.ts +35 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -0
- package/{esm → dist-esm/src}/models/parameters.js +157 -106
- package/dist-esm/src/models/parameters.js.map +1 -0
- package/dist-esm/src/operations/customizationPolicies.d.ts +46 -0
- package/dist-esm/src/operations/customizationPolicies.d.ts.map +1 -0
- package/dist-esm/src/operations/customizationPolicies.js +169 -0
- package/dist-esm/src/operations/customizationPolicies.js.map +1 -0
- package/dist-esm/src/operations/dedicatedCloudNodes.d.ts +92 -0
- package/dist-esm/src/operations/dedicatedCloudNodes.d.ts.map +1 -0
- package/dist-esm/src/operations/dedicatedCloudNodes.js +446 -0
- package/dist-esm/src/operations/dedicatedCloudNodes.js.map +1 -0
- package/dist-esm/src/operations/dedicatedCloudServices.d.ts +91 -0
- package/dist-esm/src/operations/dedicatedCloudServices.d.ts.map +1 -0
- package/dist-esm/src/operations/dedicatedCloudServices.js +431 -0
- package/dist-esm/src/operations/dedicatedCloudServices.js.map +1 -0
- package/{esm → dist-esm/src}/operations/index.d.ts +1 -0
- package/dist-esm/src/operations/index.d.ts.map +1 -0
- package/{esm → dist-esm/src}/operations/index.js +4 -5
- package/dist-esm/src/operations/index.js.map +1 -0
- package/dist-esm/src/operations/operations.d.ts +39 -0
- package/dist-esm/src/operations/operations.d.ts.map +1 -0
- package/dist-esm/src/operations/operations.js +155 -0
- package/dist-esm/src/operations/operations.js.map +1 -0
- package/dist-esm/src/operations/privateClouds.d.ts +42 -0
- package/dist-esm/src/operations/privateClouds.d.ts.map +1 -0
- package/dist-esm/src/operations/privateClouds.js +162 -0
- package/dist-esm/src/operations/privateClouds.js.map +1 -0
- package/dist-esm/src/operations/resourcePools.d.ts +46 -0
- package/dist-esm/src/operations/resourcePools.d.ts.map +1 -0
- package/dist-esm/src/operations/resourcePools.js +169 -0
- package/dist-esm/src/operations/resourcePools.js.map +1 -0
- package/dist-esm/src/operations/skusAvailability.d.ts +35 -0
- package/dist-esm/src/operations/skusAvailability.d.ts.map +1 -0
- package/dist-esm/src/operations/skusAvailability.js +132 -0
- package/dist-esm/src/operations/skusAvailability.js.map +1 -0
- package/dist-esm/src/operations/usages.d.ts +35 -0
- package/dist-esm/src/operations/usages.d.ts.map +1 -0
- package/dist-esm/src/operations/usages.js +132 -0
- package/dist-esm/src/operations/usages.js.map +1 -0
- package/dist-esm/src/operations/virtualMachineTemplates.d.ts +49 -0
- package/dist-esm/src/operations/virtualMachineTemplates.d.ts.map +1 -0
- package/dist-esm/src/operations/virtualMachineTemplates.js +172 -0
- package/dist-esm/src/operations/virtualMachineTemplates.js.map +1 -0
- package/dist-esm/src/operations/virtualMachines.d.ts +135 -0
- package/dist-esm/src/operations/virtualMachines.d.ts.map +1 -0
- package/dist-esm/src/operations/virtualMachines.js +687 -0
- package/dist-esm/src/operations/virtualMachines.js.map +1 -0
- package/dist-esm/src/operations/virtualNetworks.d.ts +49 -0
- package/dist-esm/src/operations/virtualNetworks.d.ts.map +1 -0
- package/dist-esm/src/operations/virtualNetworks.js +172 -0
- package/dist-esm/src/operations/virtualNetworks.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/customizationPolicies.d.ts +21 -0
- package/dist-esm/src/operationsInterfaces/customizationPolicies.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/customizationPolicies.js +9 -0
- package/dist-esm/src/operationsInterfaces/customizationPolicies.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudNodes.d.ts +56 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudNodes.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudNodes.js +9 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudNodes.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudServices.d.ts +55 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudServices.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudServices.js +9 -0
- package/dist-esm/src/operationsInterfaces/dedicatedCloudServices.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts +12 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.js +19 -0
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts +18 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.js +9 -0
- package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/privateClouds.d.ts +19 -0
- package/dist-esm/src/operationsInterfaces/privateClouds.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/privateClouds.js +9 -0
- package/dist-esm/src/operationsInterfaces/privateClouds.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/resourcePools.d.ts +21 -0
- package/dist-esm/src/operationsInterfaces/resourcePools.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/resourcePools.js +9 -0
- package/dist-esm/src/operationsInterfaces/resourcePools.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/skusAvailability.d.ts +12 -0
- package/dist-esm/src/operationsInterfaces/skusAvailability.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/skusAvailability.js +9 -0
- package/dist-esm/src/operationsInterfaces/skusAvailability.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/usages.d.ts +12 -0
- package/dist-esm/src/operationsInterfaces/usages.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/usages.js +9 -0
- package/dist-esm/src/operationsInterfaces/usages.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineTemplates.d.ts +22 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineTemplates.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineTemplates.js +9 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineTemplates.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.d.ts +99 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.js +9 -0
- package/dist-esm/src/operationsInterfaces/virtualMachines.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualNetworks.d.ts +22 -0
- package/dist-esm/src/operationsInterfaces/virtualNetworks.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualNetworks.js +9 -0
- package/dist-esm/src/operationsInterfaces/virtualNetworks.js.map +1 -0
- package/dist-esm/src/vMwareCloudSimple.d.ts +30 -0
- package/dist-esm/src/vMwareCloudSimple.d.ts.map +1 -0
- package/dist-esm/src/vMwareCloudSimple.js +66 -0
- package/dist-esm/src/vMwareCloudSimple.js.map +1 -0
- package/dist-esm/test/sampleTest.d.ts +2 -0
- package/dist-esm/test/sampleTest.d.ts.map +1 -0
- package/dist-esm/test/sampleTest.js +40 -0
- package/dist-esm/test/sampleTest.js.map +1 -0
- package/package.json +70 -32
- package/review/arm-vmwarecloudsimple.api.md +1140 -0
- package/rollup.config.js +181 -30
- package/src/index.ts +12 -0
- package/src/lroImpl.ts +34 -0
- package/src/models/index.ts +1155 -1956
- package/src/models/mappers.ts +1229 -846
- package/src/models/parameters.ts +200 -107
- package/src/operations/customizationPolicies.ts +217 -0
- package/src/operations/dedicatedCloudNodes.ts +391 -317
- package/src/operations/dedicatedCloudServices.ts +372 -319
- package/src/operations/index.ts +4 -5
- package/src/operations/operations.ts +117 -125
- package/src/operations/privateClouds.ts +131 -123
- package/src/operations/resourcePools.ts +145 -129
- package/src/operations/skusAvailability.ts +109 -85
- package/src/operations/usages.ts +109 -85
- package/src/operations/virtualMachineTemplates.ts +162 -132
- package/src/operations/virtualMachines.ts +705 -403
- package/src/operations/virtualNetworks.ts +163 -136
- package/src/operationsInterfaces/customizationPolicies.ts +44 -0
- package/src/operationsInterfaces/dedicatedCloudNodes.ts +110 -0
- package/src/operationsInterfaces/dedicatedCloudServices.ts +103 -0
- package/src/operationsInterfaces/index.ts +19 -0
- package/src/operationsInterfaces/operations.ts +38 -0
- package/src/operationsInterfaces/privateClouds.ts +40 -0
- package/src/operationsInterfaces/resourcePools.ts +44 -0
- package/src/operationsInterfaces/skusAvailability.ts +24 -0
- package/src/operationsInterfaces/usages.ts +24 -0
- package/src/operationsInterfaces/virtualMachineTemplates.ts +46 -0
- package/src/operationsInterfaces/virtualMachines.ts +191 -0
- package/src/operationsInterfaces/virtualNetworks.ts +46 -0
- package/src/vMwareCloudSimple.ts +126 -0
- package/tsconfig.json +3 -3
- package/types/arm-vmwarecloudsimple.d.ts +1861 -0
- package/types/tsdoc-metadata.json +11 -0
- package/dist/arm-vmwarecloudsimple.js +0 -4540
- package/dist/arm-vmwarecloudsimple.js.map +0 -1
- package/dist/arm-vmwarecloudsimple.min.js +0 -1
- package/dist/arm-vmwarecloudsimple.min.js.map +0 -1
- package/esm/models/dedicatedCloudNodesMappers.d.ts +0 -2
- package/esm/models/dedicatedCloudNodesMappers.d.ts.map +0 -1
- package/esm/models/dedicatedCloudNodesMappers.js +0 -9
- package/esm/models/dedicatedCloudNodesMappers.js.map +0 -1
- package/esm/models/dedicatedCloudServicesMappers.d.ts +0 -2
- package/esm/models/dedicatedCloudServicesMappers.d.ts.map +0 -1
- package/esm/models/dedicatedCloudServicesMappers.js +0 -9
- package/esm/models/dedicatedCloudServicesMappers.js.map +0 -1
- package/esm/models/index.d.ts +0 -2190
- package/esm/models/index.d.ts.map +0 -1
- package/esm/models/index.js +0 -8
- package/esm/models/index.js.map +0 -1
- package/esm/models/mappers.d.ts +0 -46
- package/esm/models/mappers.d.ts.map +0 -1
- package/esm/models/mappers.js.map +0 -1
- package/esm/models/operationsMappers.d.ts +0 -2
- package/esm/models/operationsMappers.d.ts.map +0 -1
- package/esm/models/operationsMappers.js +0 -9
- package/esm/models/operationsMappers.js.map +0 -1
- package/esm/models/parameters.d.ts +0 -24
- package/esm/models/parameters.d.ts.map +0 -1
- package/esm/models/parameters.js.map +0 -1
- package/esm/models/privateCloudsMappers.d.ts +0 -2
- package/esm/models/privateCloudsMappers.d.ts.map +0 -1
- package/esm/models/privateCloudsMappers.js +0 -9
- package/esm/models/privateCloudsMappers.js.map +0 -1
- package/esm/models/resourcePoolsMappers.d.ts +0 -2
- package/esm/models/resourcePoolsMappers.d.ts.map +0 -1
- package/esm/models/resourcePoolsMappers.js +0 -9
- package/esm/models/resourcePoolsMappers.js.map +0 -1
- package/esm/models/skusAvailabilityMappers.d.ts +0 -2
- package/esm/models/skusAvailabilityMappers.d.ts.map +0 -1
- package/esm/models/skusAvailabilityMappers.js +0 -9
- package/esm/models/skusAvailabilityMappers.js.map +0 -1
- package/esm/models/usagesMappers.d.ts +0 -2
- package/esm/models/usagesMappers.d.ts.map +0 -1
- package/esm/models/usagesMappers.js +0 -9
- package/esm/models/usagesMappers.js.map +0 -1
- package/esm/models/virtualMachineTemplatesMappers.d.ts +0 -2
- package/esm/models/virtualMachineTemplatesMappers.d.ts.map +0 -1
- package/esm/models/virtualMachineTemplatesMappers.js +0 -9
- package/esm/models/virtualMachineTemplatesMappers.js.map +0 -1
- package/esm/models/virtualMachinesMappers.d.ts +0 -2
- package/esm/models/virtualMachinesMappers.d.ts.map +0 -1
- package/esm/models/virtualMachinesMappers.js +0 -9
- package/esm/models/virtualMachinesMappers.js.map +0 -1
- package/esm/models/virtualNetworksMappers.d.ts +0 -2
- package/esm/models/virtualNetworksMappers.d.ts.map +0 -1
- package/esm/models/virtualNetworksMappers.js +0 -9
- package/esm/models/virtualNetworksMappers.js.map +0 -1
- package/esm/operations/dedicatedCloudNodes.d.ts +0 -173
- package/esm/operations/dedicatedCloudNodes.d.ts.map +0 -1
- package/esm/operations/dedicatedCloudNodes.js +0 -304
- package/esm/operations/dedicatedCloudNodes.js.map +0 -1
- package/esm/operations/dedicatedCloudServices.d.ts +0 -174
- package/esm/operations/dedicatedCloudServices.d.ts.map +0 -1
- package/esm/operations/dedicatedCloudServices.js +0 -300
- package/esm/operations/dedicatedCloudServices.js.map +0 -1
- package/esm/operations/index.d.ts.map +0 -1
- package/esm/operations/index.js.map +0 -1
- package/esm/operations/operations.d.ts +0 -70
- package/esm/operations/operations.d.ts.map +0 -1
- package/esm/operations/operations.js +0 -116
- package/esm/operations/operations.js.map +0 -1
- package/esm/operations/privateClouds.d.ts +0 -73
- package/esm/operations/privateClouds.d.ts.map +0 -1
- package/esm/operations/privateClouds.js +0 -113
- package/esm/operations/privateClouds.js.map +0 -1
- package/esm/operations/resourcePools.d.ts +0 -79
- package/esm/operations/resourcePools.d.ts.map +0 -1
- package/esm/operations/resourcePools.js +0 -117
- package/esm/operations/resourcePools.js.map +0 -1
- package/esm/operations/skusAvailability.d.ts +0 -51
- package/esm/operations/skusAvailability.d.ts.map +0 -1
- package/esm/operations/skusAvailability.js +0 -83
- package/esm/operations/skusAvailability.js.map +0 -1
- package/esm/operations/usages.d.ts +0 -51
- package/esm/operations/usages.d.ts.map +0 -1
- package/esm/operations/usages.js +0 -83
- package/esm/operations/usages.js.map +0 -1
- package/esm/operations/virtualMachineTemplates.d.ts +0 -82
- package/esm/operations/virtualMachineTemplates.d.ts.map +0 -1
- package/esm/operations/virtualMachineTemplates.js +0 -119
- package/esm/operations/virtualMachineTemplates.js.map +0 -1
- package/esm/operations/virtualMachines.d.ts +0 -201
- package/esm/operations/virtualMachines.d.ts.map +0 -1
- package/esm/operations/virtualMachines.js +0 -472
- package/esm/operations/virtualMachines.js.map +0 -1
- package/esm/operations/virtualNetworks.d.ts +0 -85
- package/esm/operations/virtualNetworks.d.ts.map +0 -1
- package/esm/operations/virtualNetworks.js +0 -119
- package/esm/operations/virtualNetworks.js.map +0 -1
- package/esm/vMwareCloudSimpleClient.d.ts +0 -34
- package/esm/vMwareCloudSimpleClient.d.ts.map +0 -1
- package/esm/vMwareCloudSimpleClient.js +0 -48
- package/esm/vMwareCloudSimpleClient.js.map +0 -1
- package/esm/vMwareCloudSimpleClientContext.d.ts +0 -24
- package/esm/vMwareCloudSimpleClientContext.d.ts.map +0 -1
- package/esm/vMwareCloudSimpleClientContext.js +0 -66
- package/esm/vMwareCloudSimpleClientContext.js.map +0 -1
- package/src/models/dedicatedCloudNodesMappers.ts +0 -26
- package/src/models/dedicatedCloudServicesMappers.ts +0 -25
- package/src/models/operationsMappers.ts +0 -20
- package/src/models/privateCloudsMappers.ts +0 -20
- package/src/models/resourcePoolsMappers.ts +0 -14
- package/src/models/skusAvailabilityMappers.ts +0 -14
- package/src/models/usagesMappers.ts +0 -15
- package/src/models/virtualMachineTemplatesMappers.ts +0 -18
- package/src/models/virtualMachinesMappers.ts +0 -29
- package/src/models/virtualNetworksMappers.ts +0 -14
- package/src/vMwareCloudSimpleClient.ts +0 -67
- package/src/vMwareCloudSimpleClientContext.ts +0 -74
|
@@ -1,443 +1,729 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Copyright (c) Microsoft Corporation.
|
|
3
|
-
* Licensed under the MIT License.
|
|
4
|
-
* license information.
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
5
4
|
*
|
|
6
5
|
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
7
|
-
* Changes may cause incorrect behavior and will be lost if the code is
|
|
8
|
-
* regenerated.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
9
7
|
*/
|
|
10
8
|
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import * as
|
|
14
|
-
import * as Mappers from "../models/
|
|
9
|
+
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
10
|
+
import { VirtualMachines } from "../operationsInterfaces";
|
|
11
|
+
import * as coreClient from "@azure/core-client";
|
|
12
|
+
import * as Mappers from "../models/mappers";
|
|
15
13
|
import * as Parameters from "../models/parameters";
|
|
16
|
-
import {
|
|
14
|
+
import { VMwareCloudSimple } from "../vMwareCloudSimple";
|
|
15
|
+
import { PollerLike, PollOperationState, LroEngine } from "@azure/core-lro";
|
|
16
|
+
import { LroImpl } from "../lroImpl";
|
|
17
|
+
import {
|
|
18
|
+
VirtualMachine,
|
|
19
|
+
VirtualMachinesListBySubscriptionNextOptionalParams,
|
|
20
|
+
VirtualMachinesListBySubscriptionOptionalParams,
|
|
21
|
+
VirtualMachinesListByResourceGroupNextOptionalParams,
|
|
22
|
+
VirtualMachinesListByResourceGroupOptionalParams,
|
|
23
|
+
VirtualMachinesListBySubscriptionResponse,
|
|
24
|
+
VirtualMachinesListByResourceGroupResponse,
|
|
25
|
+
VirtualMachinesGetOptionalParams,
|
|
26
|
+
VirtualMachinesGetResponse,
|
|
27
|
+
VirtualMachinesCreateOrUpdateOptionalParams,
|
|
28
|
+
VirtualMachinesCreateOrUpdateResponse,
|
|
29
|
+
VirtualMachinesDeleteOptionalParams,
|
|
30
|
+
VirtualMachinesDeleteResponse,
|
|
31
|
+
PatchPayload,
|
|
32
|
+
VirtualMachinesUpdateOptionalParams,
|
|
33
|
+
VirtualMachinesUpdateResponse,
|
|
34
|
+
VirtualMachinesStartOptionalParams,
|
|
35
|
+
VirtualMachinesStopOptionalParams,
|
|
36
|
+
VirtualMachinesListBySubscriptionNextResponse,
|
|
37
|
+
VirtualMachinesListByResourceGroupNextResponse
|
|
38
|
+
} from "../models";
|
|
17
39
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
40
|
+
/// <reference lib="esnext.asynciterable" />
|
|
41
|
+
/** Class containing VirtualMachines operations. */
|
|
42
|
+
export class VirtualMachinesImpl implements VirtualMachines {
|
|
43
|
+
private readonly client: VMwareCloudSimple;
|
|
21
44
|
|
|
22
45
|
/**
|
|
23
|
-
*
|
|
24
|
-
* @param
|
|
46
|
+
* Initialize a new instance of the class VirtualMachines class.
|
|
47
|
+
* @param client Reference to the service client
|
|
25
48
|
*/
|
|
26
|
-
constructor(client:
|
|
49
|
+
constructor(client: VMwareCloudSimple) {
|
|
27
50
|
this.client = client;
|
|
28
51
|
}
|
|
29
52
|
|
|
30
53
|
/**
|
|
31
54
|
* Returns list virtual machine within subscription
|
|
32
|
-
* @
|
|
33
|
-
* @param [options] The optional parameters
|
|
34
|
-
* @returns Promise<Models.VirtualMachinesListBySubscriptionResponse>
|
|
55
|
+
* @param options The options parameters.
|
|
35
56
|
*/
|
|
36
|
-
listBySubscription(
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
listBySubscription(options?: Models.VirtualMachinesListBySubscriptionOptionalParams | msRest.ServiceCallback<Models.VirtualMachineListResponse>, callback?: msRest.ServiceCallback<Models.VirtualMachineListResponse>): Promise<Models.VirtualMachinesListBySubscriptionResponse> {
|
|
47
|
-
return this.client.sendOperationRequest(
|
|
48
|
-
{
|
|
49
|
-
options
|
|
57
|
+
public listBySubscription(
|
|
58
|
+
options?: VirtualMachinesListBySubscriptionOptionalParams
|
|
59
|
+
): PagedAsyncIterableIterator<VirtualMachine> {
|
|
60
|
+
const iter = this.listBySubscriptionPagingAll(options);
|
|
61
|
+
return {
|
|
62
|
+
next() {
|
|
63
|
+
return iter.next();
|
|
64
|
+
},
|
|
65
|
+
[Symbol.asyncIterator]() {
|
|
66
|
+
return this;
|
|
50
67
|
},
|
|
51
|
-
|
|
52
|
-
|
|
68
|
+
byPage: () => {
|
|
69
|
+
return this.listBySubscriptionPagingPage(options);
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
private async *listBySubscriptionPagingPage(
|
|
75
|
+
options?: VirtualMachinesListBySubscriptionOptionalParams
|
|
76
|
+
): AsyncIterableIterator<VirtualMachine[]> {
|
|
77
|
+
let result = await this._listBySubscription(options);
|
|
78
|
+
yield result.value || [];
|
|
79
|
+
let continuationToken = result.nextLink;
|
|
80
|
+
while (continuationToken) {
|
|
81
|
+
result = await this._listBySubscriptionNext(continuationToken, options);
|
|
82
|
+
continuationToken = result.nextLink;
|
|
83
|
+
yield result.value || [];
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
private async *listBySubscriptionPagingAll(
|
|
88
|
+
options?: VirtualMachinesListBySubscriptionOptionalParams
|
|
89
|
+
): AsyncIterableIterator<VirtualMachine> {
|
|
90
|
+
for await (const page of this.listBySubscriptionPagingPage(options)) {
|
|
91
|
+
yield* page;
|
|
92
|
+
}
|
|
53
93
|
}
|
|
54
94
|
|
|
55
95
|
/**
|
|
56
96
|
* Returns list of virtual machine within resource group
|
|
57
|
-
* @summary Implements list virtual machine within RG method
|
|
58
97
|
* @param resourceGroupName The name of the resource group
|
|
59
|
-
* @param
|
|
60
|
-
* @returns Promise<Models.VirtualMachinesListByResourceGroupResponse>
|
|
98
|
+
* @param options The options parameters.
|
|
61
99
|
*/
|
|
62
|
-
listByResourceGroup(
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
100
|
+
public listByResourceGroup(
|
|
101
|
+
resourceGroupName: string,
|
|
102
|
+
options?: VirtualMachinesListByResourceGroupOptionalParams
|
|
103
|
+
): PagedAsyncIterableIterator<VirtualMachine> {
|
|
104
|
+
const iter = this.listByResourceGroupPagingAll(resourceGroupName, options);
|
|
105
|
+
return {
|
|
106
|
+
next() {
|
|
107
|
+
return iter.next();
|
|
108
|
+
},
|
|
109
|
+
[Symbol.asyncIterator]() {
|
|
110
|
+
return this;
|
|
111
|
+
},
|
|
112
|
+
byPage: () => {
|
|
113
|
+
return this.listByResourceGroupPagingPage(resourceGroupName, options);
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
private async *listByResourceGroupPagingPage(
|
|
119
|
+
resourceGroupName: string,
|
|
120
|
+
options?: VirtualMachinesListByResourceGroupOptionalParams
|
|
121
|
+
): AsyncIterableIterator<VirtualMachine[]> {
|
|
122
|
+
let result = await this._listByResourceGroup(resourceGroupName, options);
|
|
123
|
+
yield result.value || [];
|
|
124
|
+
let continuationToken = result.nextLink;
|
|
125
|
+
while (continuationToken) {
|
|
126
|
+
result = await this._listByResourceGroupNext(
|
|
77
127
|
resourceGroupName,
|
|
128
|
+
continuationToken,
|
|
78
129
|
options
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
130
|
+
);
|
|
131
|
+
continuationToken = result.nextLink;
|
|
132
|
+
yield result.value || [];
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
private async *listByResourceGroupPagingAll(
|
|
137
|
+
resourceGroupName: string,
|
|
138
|
+
options?: VirtualMachinesListByResourceGroupOptionalParams
|
|
139
|
+
): AsyncIterableIterator<VirtualMachine> {
|
|
140
|
+
for await (const page of this.listByResourceGroupPagingPage(
|
|
141
|
+
resourceGroupName,
|
|
142
|
+
options
|
|
143
|
+
)) {
|
|
144
|
+
yield* page;
|
|
145
|
+
}
|
|
82
146
|
}
|
|
83
147
|
|
|
84
148
|
/**
|
|
85
|
-
*
|
|
86
|
-
* @
|
|
87
|
-
* @param resourceGroupName The name of the resource group
|
|
88
|
-
* @param virtualMachineName virtual machine name
|
|
89
|
-
* @param [options] The optional parameters
|
|
90
|
-
* @returns Promise<Models.VirtualMachinesGetResponse>
|
|
149
|
+
* Returns list virtual machine within subscription
|
|
150
|
+
* @param options The options parameters.
|
|
91
151
|
*/
|
|
92
|
-
|
|
152
|
+
private _listBySubscription(
|
|
153
|
+
options?: VirtualMachinesListBySubscriptionOptionalParams
|
|
154
|
+
): Promise<VirtualMachinesListBySubscriptionResponse> {
|
|
155
|
+
return this.client.sendOperationRequest(
|
|
156
|
+
{ options },
|
|
157
|
+
listBySubscriptionOperationSpec
|
|
158
|
+
);
|
|
159
|
+
}
|
|
160
|
+
|
|
93
161
|
/**
|
|
162
|
+
* Returns list of virtual machine within resource group
|
|
94
163
|
* @param resourceGroupName The name of the resource group
|
|
95
|
-
* @param
|
|
96
|
-
* @param callback The callback
|
|
164
|
+
* @param options The options parameters.
|
|
97
165
|
*/
|
|
98
|
-
|
|
166
|
+
private _listByResourceGroup(
|
|
167
|
+
resourceGroupName: string,
|
|
168
|
+
options?: VirtualMachinesListByResourceGroupOptionalParams
|
|
169
|
+
): Promise<VirtualMachinesListByResourceGroupResponse> {
|
|
170
|
+
return this.client.sendOperationRequest(
|
|
171
|
+
{ resourceGroupName, options },
|
|
172
|
+
listByResourceGroupOperationSpec
|
|
173
|
+
);
|
|
174
|
+
}
|
|
175
|
+
|
|
99
176
|
/**
|
|
177
|
+
* Get virtual machine
|
|
100
178
|
* @param resourceGroupName The name of the resource group
|
|
101
179
|
* @param virtualMachineName virtual machine name
|
|
102
|
-
* @param options The
|
|
103
|
-
* @param callback The callback
|
|
180
|
+
* @param options The options parameters.
|
|
104
181
|
*/
|
|
105
|
-
get(
|
|
106
|
-
|
|
182
|
+
get(
|
|
183
|
+
resourceGroupName: string,
|
|
184
|
+
virtualMachineName: string,
|
|
185
|
+
options?: VirtualMachinesGetOptionalParams
|
|
186
|
+
): Promise<VirtualMachinesGetResponse> {
|
|
107
187
|
return this.client.sendOperationRequest(
|
|
108
|
-
{
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
options
|
|
112
|
-
},
|
|
113
|
-
getOperationSpec,
|
|
114
|
-
callback) as Promise<Models.VirtualMachinesGetResponse>;
|
|
188
|
+
{ resourceGroupName, virtualMachineName, options },
|
|
189
|
+
getOperationSpec
|
|
190
|
+
);
|
|
115
191
|
}
|
|
116
192
|
|
|
117
193
|
/**
|
|
118
194
|
* Create Or Update Virtual Machine
|
|
119
|
-
* @summary Implements virtual machine PUT method
|
|
120
195
|
* @param resourceGroupName The name of the resource group
|
|
121
196
|
* @param virtualMachineName virtual machine name
|
|
122
197
|
* @param virtualMachineRequest Create or Update Virtual Machine request
|
|
123
|
-
* @param
|
|
124
|
-
* @returns Promise<Models.VirtualMachinesCreateOrUpdateResponse>
|
|
198
|
+
* @param options The options parameters.
|
|
125
199
|
*/
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
200
|
+
async beginCreateOrUpdate(
|
|
201
|
+
resourceGroupName: string,
|
|
202
|
+
virtualMachineName: string,
|
|
203
|
+
virtualMachineRequest: VirtualMachine,
|
|
204
|
+
options?: VirtualMachinesCreateOrUpdateOptionalParams
|
|
205
|
+
): Promise<
|
|
206
|
+
PollerLike<
|
|
207
|
+
PollOperationState<VirtualMachinesCreateOrUpdateResponse>,
|
|
208
|
+
VirtualMachinesCreateOrUpdateResponse
|
|
209
|
+
>
|
|
210
|
+
> {
|
|
211
|
+
const directSendOperation = async (
|
|
212
|
+
args: coreClient.OperationArguments,
|
|
213
|
+
spec: coreClient.OperationSpec
|
|
214
|
+
): Promise<VirtualMachinesCreateOrUpdateResponse> => {
|
|
215
|
+
return this.client.sendOperationRequest(args, spec);
|
|
216
|
+
};
|
|
217
|
+
const sendOperation = async (
|
|
218
|
+
args: coreClient.OperationArguments,
|
|
219
|
+
spec: coreClient.OperationSpec
|
|
220
|
+
) => {
|
|
221
|
+
let currentRawResponse:
|
|
222
|
+
| coreClient.FullOperationResponse
|
|
223
|
+
| undefined = undefined;
|
|
224
|
+
const providedCallback = args.options?.onResponse;
|
|
225
|
+
const callback: coreClient.RawResponseCallback = (
|
|
226
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
227
|
+
flatResponse: unknown
|
|
228
|
+
) => {
|
|
229
|
+
currentRawResponse = rawResponse;
|
|
230
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
231
|
+
};
|
|
232
|
+
const updatedArgs = {
|
|
233
|
+
...args,
|
|
234
|
+
options: {
|
|
235
|
+
...args.options,
|
|
236
|
+
onResponse: callback
|
|
237
|
+
}
|
|
238
|
+
};
|
|
239
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
240
|
+
return {
|
|
241
|
+
flatResponse,
|
|
242
|
+
rawResponse: {
|
|
243
|
+
statusCode: currentRawResponse!.status,
|
|
244
|
+
body: currentRawResponse!.parsedBody,
|
|
245
|
+
headers: currentRawResponse!.headers.toJSON()
|
|
246
|
+
}
|
|
247
|
+
};
|
|
248
|
+
};
|
|
249
|
+
|
|
250
|
+
const lro = new LroImpl(
|
|
251
|
+
sendOperation,
|
|
252
|
+
{ resourceGroupName, virtualMachineName, virtualMachineRequest, options },
|
|
253
|
+
createOrUpdateOperationSpec
|
|
254
|
+
);
|
|
255
|
+
return new LroEngine(lro, {
|
|
256
|
+
resumeFrom: options?.resumeFrom,
|
|
257
|
+
intervalInMs: options?.updateIntervalInMs
|
|
258
|
+
});
|
|
129
259
|
}
|
|
130
260
|
|
|
131
261
|
/**
|
|
132
|
-
*
|
|
133
|
-
* @summary Implements virtual machine DELETE method
|
|
262
|
+
* Create Or Update Virtual Machine
|
|
134
263
|
* @param resourceGroupName The name of the resource group
|
|
135
264
|
* @param virtualMachineName virtual machine name
|
|
136
|
-
* @param
|
|
137
|
-
* @
|
|
265
|
+
* @param virtualMachineRequest Create or Update Virtual Machine request
|
|
266
|
+
* @param options The options parameters.
|
|
138
267
|
*/
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
268
|
+
async beginCreateOrUpdateAndWait(
|
|
269
|
+
resourceGroupName: string,
|
|
270
|
+
virtualMachineName: string,
|
|
271
|
+
virtualMachineRequest: VirtualMachine,
|
|
272
|
+
options?: VirtualMachinesCreateOrUpdateOptionalParams
|
|
273
|
+
): Promise<VirtualMachinesCreateOrUpdateResponse> {
|
|
274
|
+
const poller = await this.beginCreateOrUpdate(
|
|
275
|
+
resourceGroupName,
|
|
276
|
+
virtualMachineName,
|
|
277
|
+
virtualMachineRequest,
|
|
278
|
+
options
|
|
279
|
+
);
|
|
280
|
+
return poller.pollUntilDone();
|
|
142
281
|
}
|
|
143
282
|
|
|
144
283
|
/**
|
|
145
|
-
*
|
|
146
|
-
* @summary Implements virtual machine PATCH method
|
|
284
|
+
* Delete virtual machine
|
|
147
285
|
* @param resourceGroupName The name of the resource group
|
|
148
286
|
* @param virtualMachineName virtual machine name
|
|
149
|
-
* @param
|
|
150
|
-
* @returns Promise<Models.VirtualMachinesUpdateResponse>
|
|
287
|
+
* @param options The options parameters.
|
|
151
288
|
*/
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
289
|
+
async beginDelete(
|
|
290
|
+
resourceGroupName: string,
|
|
291
|
+
virtualMachineName: string,
|
|
292
|
+
options?: VirtualMachinesDeleteOptionalParams
|
|
293
|
+
): Promise<
|
|
294
|
+
PollerLike<
|
|
295
|
+
PollOperationState<VirtualMachinesDeleteResponse>,
|
|
296
|
+
VirtualMachinesDeleteResponse
|
|
297
|
+
>
|
|
298
|
+
> {
|
|
299
|
+
const directSendOperation = async (
|
|
300
|
+
args: coreClient.OperationArguments,
|
|
301
|
+
spec: coreClient.OperationSpec
|
|
302
|
+
): Promise<VirtualMachinesDeleteResponse> => {
|
|
303
|
+
return this.client.sendOperationRequest(args, spec);
|
|
304
|
+
};
|
|
305
|
+
const sendOperation = async (
|
|
306
|
+
args: coreClient.OperationArguments,
|
|
307
|
+
spec: coreClient.OperationSpec
|
|
308
|
+
) => {
|
|
309
|
+
let currentRawResponse:
|
|
310
|
+
| coreClient.FullOperationResponse
|
|
311
|
+
| undefined = undefined;
|
|
312
|
+
const providedCallback = args.options?.onResponse;
|
|
313
|
+
const callback: coreClient.RawResponseCallback = (
|
|
314
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
315
|
+
flatResponse: unknown
|
|
316
|
+
) => {
|
|
317
|
+
currentRawResponse = rawResponse;
|
|
318
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
319
|
+
};
|
|
320
|
+
const updatedArgs = {
|
|
321
|
+
...args,
|
|
322
|
+
options: {
|
|
323
|
+
...args.options,
|
|
324
|
+
onResponse: callback
|
|
325
|
+
}
|
|
326
|
+
};
|
|
327
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
328
|
+
return {
|
|
329
|
+
flatResponse,
|
|
330
|
+
rawResponse: {
|
|
331
|
+
statusCode: currentRawResponse!.status,
|
|
332
|
+
body: currentRawResponse!.parsedBody,
|
|
333
|
+
headers: currentRawResponse!.headers.toJSON()
|
|
334
|
+
}
|
|
335
|
+
};
|
|
336
|
+
};
|
|
337
|
+
|
|
338
|
+
const lro = new LroImpl(
|
|
339
|
+
sendOperation,
|
|
340
|
+
{ resourceGroupName, virtualMachineName, options },
|
|
341
|
+
deleteOperationSpec
|
|
342
|
+
);
|
|
343
|
+
return new LroEngine(lro, {
|
|
344
|
+
resumeFrom: options?.resumeFrom,
|
|
345
|
+
intervalInMs: options?.updateIntervalInMs
|
|
346
|
+
});
|
|
155
347
|
}
|
|
156
348
|
|
|
157
349
|
/**
|
|
158
|
-
*
|
|
159
|
-
* @summary Implements a start method for a virtual machine
|
|
350
|
+
* Delete virtual machine
|
|
160
351
|
* @param resourceGroupName The name of the resource group
|
|
161
352
|
* @param virtualMachineName virtual machine name
|
|
162
|
-
* @param
|
|
163
|
-
* @returns Promise<Models.VirtualMachinesStartResponse>
|
|
353
|
+
* @param options The options parameters.
|
|
164
354
|
*/
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
355
|
+
async beginDeleteAndWait(
|
|
356
|
+
resourceGroupName: string,
|
|
357
|
+
virtualMachineName: string,
|
|
358
|
+
options?: VirtualMachinesDeleteOptionalParams
|
|
359
|
+
): Promise<VirtualMachinesDeleteResponse> {
|
|
360
|
+
const poller = await this.beginDelete(
|
|
361
|
+
resourceGroupName,
|
|
362
|
+
virtualMachineName,
|
|
363
|
+
options
|
|
364
|
+
);
|
|
365
|
+
return poller.pollUntilDone();
|
|
168
366
|
}
|
|
169
367
|
|
|
170
368
|
/**
|
|
171
|
-
*
|
|
172
|
-
* @summary Implements shutdown, poweroff, and suspend method for a virtual machine
|
|
369
|
+
* Patch virtual machine properties
|
|
173
370
|
* @param resourceGroupName The name of the resource group
|
|
174
371
|
* @param virtualMachineName virtual machine name
|
|
175
|
-
* @param
|
|
176
|
-
* @
|
|
372
|
+
* @param virtualMachineRequest Patch virtual machine request
|
|
373
|
+
* @param options The options parameters.
|
|
177
374
|
*/
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
375
|
+
async beginUpdate(
|
|
376
|
+
resourceGroupName: string,
|
|
377
|
+
virtualMachineName: string,
|
|
378
|
+
virtualMachineRequest: PatchPayload,
|
|
379
|
+
options?: VirtualMachinesUpdateOptionalParams
|
|
380
|
+
): Promise<
|
|
381
|
+
PollerLike<
|
|
382
|
+
PollOperationState<VirtualMachinesUpdateResponse>,
|
|
383
|
+
VirtualMachinesUpdateResponse
|
|
384
|
+
>
|
|
385
|
+
> {
|
|
386
|
+
const directSendOperation = async (
|
|
387
|
+
args: coreClient.OperationArguments,
|
|
388
|
+
spec: coreClient.OperationSpec
|
|
389
|
+
): Promise<VirtualMachinesUpdateResponse> => {
|
|
390
|
+
return this.client.sendOperationRequest(args, spec);
|
|
391
|
+
};
|
|
392
|
+
const sendOperation = async (
|
|
393
|
+
args: coreClient.OperationArguments,
|
|
394
|
+
spec: coreClient.OperationSpec
|
|
395
|
+
) => {
|
|
396
|
+
let currentRawResponse:
|
|
397
|
+
| coreClient.FullOperationResponse
|
|
398
|
+
| undefined = undefined;
|
|
399
|
+
const providedCallback = args.options?.onResponse;
|
|
400
|
+
const callback: coreClient.RawResponseCallback = (
|
|
401
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
402
|
+
flatResponse: unknown
|
|
403
|
+
) => {
|
|
404
|
+
currentRawResponse = rawResponse;
|
|
405
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
406
|
+
};
|
|
407
|
+
const updatedArgs = {
|
|
408
|
+
...args,
|
|
409
|
+
options: {
|
|
410
|
+
...args.options,
|
|
411
|
+
onResponse: callback
|
|
412
|
+
}
|
|
413
|
+
};
|
|
414
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
415
|
+
return {
|
|
416
|
+
flatResponse,
|
|
417
|
+
rawResponse: {
|
|
418
|
+
statusCode: currentRawResponse!.status,
|
|
419
|
+
body: currentRawResponse!.parsedBody,
|
|
420
|
+
headers: currentRawResponse!.headers.toJSON()
|
|
421
|
+
}
|
|
422
|
+
};
|
|
423
|
+
};
|
|
424
|
+
|
|
425
|
+
const lro = new LroImpl(
|
|
426
|
+
sendOperation,
|
|
427
|
+
{ resourceGroupName, virtualMachineName, virtualMachineRequest, options },
|
|
428
|
+
updateOperationSpec
|
|
429
|
+
);
|
|
430
|
+
return new LroEngine(lro, {
|
|
431
|
+
resumeFrom: options?.resumeFrom,
|
|
432
|
+
intervalInMs: options?.updateIntervalInMs
|
|
433
|
+
});
|
|
181
434
|
}
|
|
182
435
|
|
|
183
436
|
/**
|
|
184
|
-
*
|
|
185
|
-
* @summary Implements virtual machine PUT method
|
|
437
|
+
* Patch virtual machine properties
|
|
186
438
|
* @param resourceGroupName The name of the resource group
|
|
187
439
|
* @param virtualMachineName virtual machine name
|
|
188
|
-
* @param virtualMachineRequest
|
|
189
|
-
* @param
|
|
190
|
-
* @returns Promise<msRestAzure.LROPoller>
|
|
440
|
+
* @param virtualMachineRequest Patch virtual machine request
|
|
441
|
+
* @param options The options parameters.
|
|
191
442
|
*/
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
443
|
+
async beginUpdateAndWait(
|
|
444
|
+
resourceGroupName: string,
|
|
445
|
+
virtualMachineName: string,
|
|
446
|
+
virtualMachineRequest: PatchPayload,
|
|
447
|
+
options?: VirtualMachinesUpdateOptionalParams
|
|
448
|
+
): Promise<VirtualMachinesUpdateResponse> {
|
|
449
|
+
const poller = await this.beginUpdate(
|
|
450
|
+
resourceGroupName,
|
|
451
|
+
virtualMachineName,
|
|
452
|
+
virtualMachineRequest,
|
|
453
|
+
options
|
|
454
|
+
);
|
|
455
|
+
return poller.pollUntilDone();
|
|
202
456
|
}
|
|
203
457
|
|
|
204
458
|
/**
|
|
205
|
-
*
|
|
206
|
-
* @summary Implements virtual machine DELETE method
|
|
459
|
+
* Power on virtual machine
|
|
207
460
|
* @param resourceGroupName The name of the resource group
|
|
208
461
|
* @param virtualMachineName virtual machine name
|
|
209
|
-
* @param
|
|
210
|
-
* @returns Promise<msRestAzure.LROPoller>
|
|
462
|
+
* @param options The options parameters.
|
|
211
463
|
*/
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
464
|
+
async beginStart(
|
|
465
|
+
resourceGroupName: string,
|
|
466
|
+
virtualMachineName: string,
|
|
467
|
+
options?: VirtualMachinesStartOptionalParams
|
|
468
|
+
): Promise<PollerLike<PollOperationState<void>, void>> {
|
|
469
|
+
const directSendOperation = async (
|
|
470
|
+
args: coreClient.OperationArguments,
|
|
471
|
+
spec: coreClient.OperationSpec
|
|
472
|
+
): Promise<void> => {
|
|
473
|
+
return this.client.sendOperationRequest(args, spec);
|
|
474
|
+
};
|
|
475
|
+
const sendOperation = async (
|
|
476
|
+
args: coreClient.OperationArguments,
|
|
477
|
+
spec: coreClient.OperationSpec
|
|
478
|
+
) => {
|
|
479
|
+
let currentRawResponse:
|
|
480
|
+
| coreClient.FullOperationResponse
|
|
481
|
+
| undefined = undefined;
|
|
482
|
+
const providedCallback = args.options?.onResponse;
|
|
483
|
+
const callback: coreClient.RawResponseCallback = (
|
|
484
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
485
|
+
flatResponse: unknown
|
|
486
|
+
) => {
|
|
487
|
+
currentRawResponse = rawResponse;
|
|
488
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
489
|
+
};
|
|
490
|
+
const updatedArgs = {
|
|
491
|
+
...args,
|
|
492
|
+
options: {
|
|
493
|
+
...args.options,
|
|
494
|
+
onResponse: callback
|
|
495
|
+
}
|
|
496
|
+
};
|
|
497
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
498
|
+
return {
|
|
499
|
+
flatResponse,
|
|
500
|
+
rawResponse: {
|
|
501
|
+
statusCode: currentRawResponse!.status,
|
|
502
|
+
body: currentRawResponse!.parsedBody,
|
|
503
|
+
headers: currentRawResponse!.headers.toJSON()
|
|
504
|
+
}
|
|
505
|
+
};
|
|
506
|
+
};
|
|
507
|
+
|
|
508
|
+
const lro = new LroImpl(
|
|
509
|
+
sendOperation,
|
|
510
|
+
{ resourceGroupName, virtualMachineName, options },
|
|
511
|
+
startOperationSpec
|
|
512
|
+
);
|
|
513
|
+
return new LroEngine(lro, {
|
|
514
|
+
resumeFrom: options?.resumeFrom,
|
|
515
|
+
intervalInMs: options?.updateIntervalInMs
|
|
516
|
+
});
|
|
221
517
|
}
|
|
222
518
|
|
|
223
519
|
/**
|
|
224
|
-
*
|
|
225
|
-
* @summary Implements virtual machine PATCH method
|
|
520
|
+
* Power on virtual machine
|
|
226
521
|
* @param resourceGroupName The name of the resource group
|
|
227
522
|
* @param virtualMachineName virtual machine name
|
|
228
|
-
* @param
|
|
229
|
-
* @returns Promise<msRestAzure.LROPoller>
|
|
523
|
+
* @param options The options parameters.
|
|
230
524
|
*/
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
options
|
|
525
|
+
async beginStartAndWait(
|
|
526
|
+
resourceGroupName: string,
|
|
527
|
+
virtualMachineName: string,
|
|
528
|
+
options?: VirtualMachinesStartOptionalParams
|
|
529
|
+
): Promise<void> {
|
|
530
|
+
const poller = await this.beginStart(
|
|
531
|
+
resourceGroupName,
|
|
532
|
+
virtualMachineName,
|
|
533
|
+
options
|
|
534
|
+
);
|
|
535
|
+
return poller.pollUntilDone();
|
|
240
536
|
}
|
|
241
537
|
|
|
242
538
|
/**
|
|
243
|
-
* Power
|
|
244
|
-
* @summary Implements a start method for a virtual machine
|
|
539
|
+
* Power off virtual machine, options: shutdown, poweroff, and suspend
|
|
245
540
|
* @param resourceGroupName The name of the resource group
|
|
246
541
|
* @param virtualMachineName virtual machine name
|
|
247
|
-
* @param
|
|
248
|
-
* @returns Promise<msRestAzure.LROPoller>
|
|
542
|
+
* @param options The options parameters.
|
|
249
543
|
*/
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
544
|
+
async beginStop(
|
|
545
|
+
resourceGroupName: string,
|
|
546
|
+
virtualMachineName: string,
|
|
547
|
+
options?: VirtualMachinesStopOptionalParams
|
|
548
|
+
): Promise<PollerLike<PollOperationState<void>, void>> {
|
|
549
|
+
const directSendOperation = async (
|
|
550
|
+
args: coreClient.OperationArguments,
|
|
551
|
+
spec: coreClient.OperationSpec
|
|
552
|
+
): Promise<void> => {
|
|
553
|
+
return this.client.sendOperationRequest(args, spec);
|
|
554
|
+
};
|
|
555
|
+
const sendOperation = async (
|
|
556
|
+
args: coreClient.OperationArguments,
|
|
557
|
+
spec: coreClient.OperationSpec
|
|
558
|
+
) => {
|
|
559
|
+
let currentRawResponse:
|
|
560
|
+
| coreClient.FullOperationResponse
|
|
561
|
+
| undefined = undefined;
|
|
562
|
+
const providedCallback = args.options?.onResponse;
|
|
563
|
+
const callback: coreClient.RawResponseCallback = (
|
|
564
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
565
|
+
flatResponse: unknown
|
|
566
|
+
) => {
|
|
567
|
+
currentRawResponse = rawResponse;
|
|
568
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
569
|
+
};
|
|
570
|
+
const updatedArgs = {
|
|
571
|
+
...args,
|
|
572
|
+
options: {
|
|
573
|
+
...args.options,
|
|
574
|
+
onResponse: callback
|
|
575
|
+
}
|
|
576
|
+
};
|
|
577
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
578
|
+
return {
|
|
579
|
+
flatResponse,
|
|
580
|
+
rawResponse: {
|
|
581
|
+
statusCode: currentRawResponse!.status,
|
|
582
|
+
body: currentRawResponse!.parsedBody,
|
|
583
|
+
headers: currentRawResponse!.headers.toJSON()
|
|
584
|
+
}
|
|
585
|
+
};
|
|
586
|
+
};
|
|
587
|
+
|
|
588
|
+
const lro = new LroImpl(
|
|
589
|
+
sendOperation,
|
|
590
|
+
{ resourceGroupName, virtualMachineName, options },
|
|
591
|
+
stopOperationSpec
|
|
592
|
+
);
|
|
593
|
+
return new LroEngine(lro, {
|
|
594
|
+
resumeFrom: options?.resumeFrom,
|
|
595
|
+
intervalInMs: options?.updateIntervalInMs
|
|
596
|
+
});
|
|
259
597
|
}
|
|
260
598
|
|
|
261
599
|
/**
|
|
262
600
|
* Power off virtual machine, options: shutdown, poweroff, and suspend
|
|
263
|
-
* @summary Implements shutdown, poweroff, and suspend method for a virtual machine
|
|
264
601
|
* @param resourceGroupName The name of the resource group
|
|
265
602
|
* @param virtualMachineName virtual machine name
|
|
266
|
-
* @param
|
|
267
|
-
* @returns Promise<msRestAzure.LROPoller>
|
|
603
|
+
* @param options The options parameters.
|
|
268
604
|
*/
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
options
|
|
605
|
+
async beginStopAndWait(
|
|
606
|
+
resourceGroupName: string,
|
|
607
|
+
virtualMachineName: string,
|
|
608
|
+
options?: VirtualMachinesStopOptionalParams
|
|
609
|
+
): Promise<void> {
|
|
610
|
+
const poller = await this.beginStop(
|
|
611
|
+
resourceGroupName,
|
|
612
|
+
virtualMachineName,
|
|
613
|
+
options
|
|
614
|
+
);
|
|
615
|
+
return poller.pollUntilDone();
|
|
278
616
|
}
|
|
279
617
|
|
|
280
618
|
/**
|
|
281
|
-
*
|
|
282
|
-
* @
|
|
283
|
-
* @param
|
|
284
|
-
* @param [options] The optional parameters
|
|
285
|
-
* @returns Promise<Models.VirtualMachinesListBySubscriptionNextResponse>
|
|
286
|
-
*/
|
|
287
|
-
listBySubscriptionNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.VirtualMachinesListBySubscriptionNextResponse>;
|
|
288
|
-
/**
|
|
289
|
-
* @param nextPageLink The NextLink from the previous successful call to List operation.
|
|
290
|
-
* @param callback The callback
|
|
619
|
+
* ListBySubscriptionNext
|
|
620
|
+
* @param nextLink The nextLink from the previous successful call to the ListBySubscription method.
|
|
621
|
+
* @param options The options parameters.
|
|
291
622
|
*/
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
* @param callback The callback
|
|
297
|
-
*/
|
|
298
|
-
listBySubscriptionNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback<Models.VirtualMachineListResponse>): void;
|
|
299
|
-
listBySubscriptionNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback<Models.VirtualMachineListResponse>, callback?: msRest.ServiceCallback<Models.VirtualMachineListResponse>): Promise<Models.VirtualMachinesListBySubscriptionNextResponse> {
|
|
623
|
+
private _listBySubscriptionNext(
|
|
624
|
+
nextLink: string,
|
|
625
|
+
options?: VirtualMachinesListBySubscriptionNextOptionalParams
|
|
626
|
+
): Promise<VirtualMachinesListBySubscriptionNextResponse> {
|
|
300
627
|
return this.client.sendOperationRequest(
|
|
301
|
-
{
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
},
|
|
305
|
-
listBySubscriptionNextOperationSpec,
|
|
306
|
-
callback) as Promise<Models.VirtualMachinesListBySubscriptionNextResponse>;
|
|
628
|
+
{ nextLink, options },
|
|
629
|
+
listBySubscriptionNextOperationSpec
|
|
630
|
+
);
|
|
307
631
|
}
|
|
308
632
|
|
|
309
633
|
/**
|
|
310
|
-
*
|
|
311
|
-
* @
|
|
312
|
-
* @param
|
|
313
|
-
* @param
|
|
314
|
-
* @returns Promise<Models.VirtualMachinesListByResourceGroupNextResponse>
|
|
315
|
-
*/
|
|
316
|
-
listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise<Models.VirtualMachinesListByResourceGroupNextResponse>;
|
|
317
|
-
/**
|
|
318
|
-
* @param nextPageLink The NextLink from the previous successful call to List operation.
|
|
319
|
-
* @param callback The callback
|
|
320
|
-
*/
|
|
321
|
-
listByResourceGroupNext(nextPageLink: string, callback: msRest.ServiceCallback<Models.VirtualMachineListResponse>): void;
|
|
322
|
-
/**
|
|
323
|
-
* @param nextPageLink The NextLink from the previous successful call to List operation.
|
|
324
|
-
* @param options The optional parameters
|
|
325
|
-
* @param callback The callback
|
|
634
|
+
* ListByResourceGroupNext
|
|
635
|
+
* @param resourceGroupName The name of the resource group
|
|
636
|
+
* @param nextLink The nextLink from the previous successful call to the ListByResourceGroup method.
|
|
637
|
+
* @param options The options parameters.
|
|
326
638
|
*/
|
|
327
|
-
|
|
328
|
-
|
|
639
|
+
private _listByResourceGroupNext(
|
|
640
|
+
resourceGroupName: string,
|
|
641
|
+
nextLink: string,
|
|
642
|
+
options?: VirtualMachinesListByResourceGroupNextOptionalParams
|
|
643
|
+
): Promise<VirtualMachinesListByResourceGroupNextResponse> {
|
|
329
644
|
return this.client.sendOperationRequest(
|
|
330
|
-
{
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
},
|
|
334
|
-
listByResourceGroupNextOperationSpec,
|
|
335
|
-
callback) as Promise<Models.VirtualMachinesListByResourceGroupNextResponse>;
|
|
645
|
+
{ resourceGroupName, nextLink, options },
|
|
646
|
+
listByResourceGroupNextOperationSpec
|
|
647
|
+
);
|
|
336
648
|
}
|
|
337
649
|
}
|
|
338
|
-
|
|
339
650
|
// Operation Specifications
|
|
340
|
-
const serializer =
|
|
341
|
-
|
|
651
|
+
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
|
652
|
+
|
|
653
|
+
const listBySubscriptionOperationSpec: coreClient.OperationSpec = {
|
|
654
|
+
path:
|
|
655
|
+
"/subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/virtualMachines",
|
|
342
656
|
httpMethod: "GET",
|
|
343
|
-
path: "subscriptions/{subscriptionId}/providers/Microsoft.VMwareCloudSimple/virtualMachines",
|
|
344
|
-
urlParameters: [
|
|
345
|
-
Parameters.subscriptionId
|
|
346
|
-
],
|
|
347
|
-
queryParameters: [
|
|
348
|
-
Parameters.apiVersion,
|
|
349
|
-
Parameters.filter,
|
|
350
|
-
Parameters.top,
|
|
351
|
-
Parameters.skipToken
|
|
352
|
-
],
|
|
353
|
-
headerParameters: [
|
|
354
|
-
Parameters.acceptLanguage
|
|
355
|
-
],
|
|
356
657
|
responses: {
|
|
357
658
|
200: {
|
|
358
659
|
bodyMapper: Mappers.VirtualMachineListResponse
|
|
359
660
|
},
|
|
360
661
|
default: {
|
|
361
|
-
bodyMapper: Mappers.
|
|
662
|
+
bodyMapper: Mappers.CsrpError
|
|
362
663
|
}
|
|
363
664
|
},
|
|
364
|
-
serializer
|
|
365
|
-
};
|
|
366
|
-
|
|
367
|
-
const listByResourceGroupOperationSpec: msRest.OperationSpec = {
|
|
368
|
-
httpMethod: "GET",
|
|
369
|
-
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines",
|
|
370
|
-
urlParameters: [
|
|
371
|
-
Parameters.subscriptionId,
|
|
372
|
-
Parameters.resourceGroupName
|
|
373
|
-
],
|
|
374
665
|
queryParameters: [
|
|
375
666
|
Parameters.apiVersion,
|
|
376
667
|
Parameters.filter,
|
|
377
668
|
Parameters.top,
|
|
378
669
|
Parameters.skipToken
|
|
379
670
|
],
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
671
|
+
urlParameters: [Parameters.$host, Parameters.subscriptionId],
|
|
672
|
+
headerParameters: [Parameters.accept],
|
|
673
|
+
serializer
|
|
674
|
+
};
|
|
675
|
+
const listByResourceGroupOperationSpec: coreClient.OperationSpec = {
|
|
676
|
+
path:
|
|
677
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines",
|
|
678
|
+
httpMethod: "GET",
|
|
383
679
|
responses: {
|
|
384
680
|
200: {
|
|
385
681
|
bodyMapper: Mappers.VirtualMachineListResponse
|
|
386
682
|
},
|
|
387
683
|
default: {
|
|
388
|
-
bodyMapper: Mappers.
|
|
684
|
+
bodyMapper: Mappers.CsrpError
|
|
389
685
|
}
|
|
390
686
|
},
|
|
391
|
-
serializer
|
|
392
|
-
};
|
|
393
|
-
|
|
394
|
-
const getOperationSpec: msRest.OperationSpec = {
|
|
395
|
-
httpMethod: "GET",
|
|
396
|
-
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
397
|
-
urlParameters: [
|
|
398
|
-
Parameters.subscriptionId,
|
|
399
|
-
Parameters.resourceGroupName,
|
|
400
|
-
Parameters.virtualMachineName0
|
|
401
|
-
],
|
|
402
687
|
queryParameters: [
|
|
403
|
-
Parameters.apiVersion
|
|
688
|
+
Parameters.apiVersion,
|
|
689
|
+
Parameters.filter,
|
|
690
|
+
Parameters.top,
|
|
691
|
+
Parameters.skipToken
|
|
404
692
|
],
|
|
405
|
-
|
|
406
|
-
Parameters
|
|
693
|
+
urlParameters: [
|
|
694
|
+
Parameters.$host,
|
|
695
|
+
Parameters.subscriptionId,
|
|
696
|
+
Parameters.resourceGroupName
|
|
407
697
|
],
|
|
698
|
+
headerParameters: [Parameters.accept],
|
|
699
|
+
serializer
|
|
700
|
+
};
|
|
701
|
+
const getOperationSpec: coreClient.OperationSpec = {
|
|
702
|
+
path:
|
|
703
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
704
|
+
httpMethod: "GET",
|
|
408
705
|
responses: {
|
|
409
706
|
200: {
|
|
410
707
|
bodyMapper: Mappers.VirtualMachine
|
|
411
708
|
},
|
|
412
709
|
default: {
|
|
413
|
-
bodyMapper: Mappers.
|
|
710
|
+
bodyMapper: Mappers.CsrpError
|
|
414
711
|
}
|
|
415
712
|
},
|
|
416
|
-
|
|
417
|
-
};
|
|
418
|
-
|
|
419
|
-
const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = {
|
|
420
|
-
httpMethod: "PUT",
|
|
421
|
-
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
713
|
+
queryParameters: [Parameters.apiVersion],
|
|
422
714
|
urlParameters: [
|
|
715
|
+
Parameters.$host,
|
|
423
716
|
Parameters.subscriptionId,
|
|
424
717
|
Parameters.resourceGroupName,
|
|
425
|
-
Parameters.
|
|
426
|
-
],
|
|
427
|
-
queryParameters: [
|
|
428
|
-
Parameters.apiVersion
|
|
718
|
+
Parameters.virtualMachineName
|
|
429
719
|
],
|
|
430
|
-
headerParameters: [
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
...Mappers.VirtualMachine,
|
|
438
|
-
required: true
|
|
439
|
-
}
|
|
440
|
-
},
|
|
720
|
+
headerParameters: [Parameters.accept],
|
|
721
|
+
serializer
|
|
722
|
+
};
|
|
723
|
+
const createOrUpdateOperationSpec: coreClient.OperationSpec = {
|
|
724
|
+
path:
|
|
725
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
726
|
+
httpMethod: "PUT",
|
|
441
727
|
responses: {
|
|
442
728
|
200: {
|
|
443
729
|
bodyMapper: Mappers.VirtualMachine,
|
|
@@ -447,29 +733,45 @@ const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = {
|
|
|
447
733
|
bodyMapper: Mappers.VirtualMachine,
|
|
448
734
|
headersMapper: Mappers.VirtualMachinesCreateOrUpdateHeaders
|
|
449
735
|
},
|
|
736
|
+
202: {
|
|
737
|
+
bodyMapper: Mappers.VirtualMachine,
|
|
738
|
+
headersMapper: Mappers.VirtualMachinesCreateOrUpdateHeaders
|
|
739
|
+
},
|
|
740
|
+
204: {
|
|
741
|
+
bodyMapper: Mappers.VirtualMachine,
|
|
742
|
+
headersMapper: Mappers.VirtualMachinesCreateOrUpdateHeaders
|
|
743
|
+
},
|
|
450
744
|
default: {
|
|
451
|
-
bodyMapper: Mappers.
|
|
745
|
+
bodyMapper: Mappers.CsrpError
|
|
452
746
|
}
|
|
453
747
|
},
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
const beginDeleteMethodOperationSpec: msRest.OperationSpec = {
|
|
458
|
-
httpMethod: "DELETE",
|
|
459
|
-
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
748
|
+
requestBody: Parameters.virtualMachineRequest,
|
|
749
|
+
queryParameters: [Parameters.apiVersion],
|
|
460
750
|
urlParameters: [
|
|
751
|
+
Parameters.$host,
|
|
461
752
|
Parameters.subscriptionId,
|
|
462
753
|
Parameters.resourceGroupName,
|
|
463
|
-
Parameters.
|
|
464
|
-
],
|
|
465
|
-
queryParameters: [
|
|
466
|
-
Parameters.apiVersion
|
|
754
|
+
Parameters.virtualMachineName1
|
|
467
755
|
],
|
|
468
756
|
headerParameters: [
|
|
757
|
+
Parameters.accept,
|
|
469
758
|
Parameters.referer,
|
|
470
|
-
Parameters.
|
|
759
|
+
Parameters.contentType
|
|
471
760
|
],
|
|
761
|
+
mediaType: "json",
|
|
762
|
+
serializer
|
|
763
|
+
};
|
|
764
|
+
const deleteOperationSpec: coreClient.OperationSpec = {
|
|
765
|
+
path:
|
|
766
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
767
|
+
httpMethod: "DELETE",
|
|
472
768
|
responses: {
|
|
769
|
+
200: {
|
|
770
|
+
headersMapper: Mappers.VirtualMachinesDeleteHeaders
|
|
771
|
+
},
|
|
772
|
+
201: {
|
|
773
|
+
headersMapper: Mappers.VirtualMachinesDeleteHeaders
|
|
774
|
+
},
|
|
473
775
|
202: {
|
|
474
776
|
headersMapper: Mappers.VirtualMachinesDeleteHeaders
|
|
475
777
|
},
|
|
@@ -477,155 +779,155 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = {
|
|
|
477
779
|
headersMapper: Mappers.VirtualMachinesDeleteHeaders
|
|
478
780
|
},
|
|
479
781
|
default: {
|
|
480
|
-
bodyMapper: Mappers.
|
|
782
|
+
bodyMapper: Mappers.CsrpError,
|
|
783
|
+
headersMapper: Mappers.VirtualMachinesDeleteExceptionHeaders
|
|
481
784
|
}
|
|
482
785
|
},
|
|
483
|
-
|
|
484
|
-
};
|
|
485
|
-
|
|
486
|
-
const beginUpdateOperationSpec: msRest.OperationSpec = {
|
|
487
|
-
httpMethod: "PATCH",
|
|
488
|
-
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
786
|
+
queryParameters: [Parameters.apiVersion],
|
|
489
787
|
urlParameters: [
|
|
788
|
+
Parameters.$host,
|
|
490
789
|
Parameters.subscriptionId,
|
|
491
790
|
Parameters.resourceGroupName,
|
|
492
|
-
Parameters.
|
|
493
|
-
],
|
|
494
|
-
queryParameters: [
|
|
495
|
-
Parameters.apiVersion
|
|
496
|
-
],
|
|
497
|
-
headerParameters: [
|
|
498
|
-
Parameters.acceptLanguage
|
|
791
|
+
Parameters.virtualMachineName
|
|
499
792
|
],
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
mapper: {
|
|
508
|
-
...Mappers.PatchPayload,
|
|
509
|
-
required: true
|
|
510
|
-
}
|
|
511
|
-
},
|
|
793
|
+
headerParameters: [Parameters.accept, Parameters.referer],
|
|
794
|
+
serializer
|
|
795
|
+
};
|
|
796
|
+
const updateOperationSpec: coreClient.OperationSpec = {
|
|
797
|
+
path:
|
|
798
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}",
|
|
799
|
+
httpMethod: "PATCH",
|
|
512
800
|
responses: {
|
|
513
801
|
200: {
|
|
514
802
|
bodyMapper: Mappers.VirtualMachine
|
|
515
803
|
},
|
|
804
|
+
201: {
|
|
805
|
+
bodyMapper: Mappers.VirtualMachine
|
|
806
|
+
},
|
|
807
|
+
202: {
|
|
808
|
+
bodyMapper: Mappers.VirtualMachine
|
|
809
|
+
},
|
|
810
|
+
204: {
|
|
811
|
+
bodyMapper: Mappers.VirtualMachine
|
|
812
|
+
},
|
|
516
813
|
default: {
|
|
517
|
-
bodyMapper: Mappers.
|
|
814
|
+
bodyMapper: Mappers.CsrpError
|
|
518
815
|
}
|
|
519
816
|
},
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
const beginStartOperationSpec: msRest.OperationSpec = {
|
|
524
|
-
httpMethod: "POST",
|
|
525
|
-
path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}/start",
|
|
817
|
+
requestBody: Parameters.virtualMachineRequest1,
|
|
818
|
+
queryParameters: [Parameters.apiVersion],
|
|
526
819
|
urlParameters: [
|
|
820
|
+
Parameters.$host,
|
|
527
821
|
Parameters.subscriptionId,
|
|
528
822
|
Parameters.resourceGroupName,
|
|
529
|
-
Parameters.
|
|
530
|
-
],
|
|
531
|
-
queryParameters: [
|
|
532
|
-
Parameters.apiVersion
|
|
533
|
-
],
|
|
534
|
-
headerParameters: [
|
|
535
|
-
Parameters.referer,
|
|
536
|
-
Parameters.acceptLanguage
|
|
823
|
+
Parameters.virtualMachineName
|
|
537
824
|
],
|
|
825
|
+
headerParameters: [Parameters.accept, Parameters.contentType],
|
|
826
|
+
mediaType: "json",
|
|
827
|
+
serializer
|
|
828
|
+
};
|
|
829
|
+
const startOperationSpec: coreClient.OperationSpec = {
|
|
830
|
+
path:
|
|
831
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}/start",
|
|
832
|
+
httpMethod: "POST",
|
|
538
833
|
responses: {
|
|
539
|
-
200: {
|
|
540
|
-
|
|
541
|
-
},
|
|
542
|
-
|
|
543
|
-
headersMapper: Mappers.VirtualMachinesStartHeaders
|
|
544
|
-
},
|
|
834
|
+
200: {},
|
|
835
|
+
201: {},
|
|
836
|
+
202: {},
|
|
837
|
+
204: {},
|
|
545
838
|
default: {
|
|
546
|
-
bodyMapper: Mappers.
|
|
839
|
+
bodyMapper: Mappers.CsrpError,
|
|
840
|
+
headersMapper: Mappers.VirtualMachinesStartExceptionHeaders
|
|
547
841
|
}
|
|
548
842
|
},
|
|
843
|
+
queryParameters: [Parameters.apiVersion],
|
|
844
|
+
urlParameters: [
|
|
845
|
+
Parameters.$host,
|
|
846
|
+
Parameters.subscriptionId,
|
|
847
|
+
Parameters.resourceGroupName,
|
|
848
|
+
Parameters.virtualMachineName
|
|
849
|
+
],
|
|
850
|
+
headerParameters: [Parameters.accept, Parameters.referer],
|
|
549
851
|
serializer
|
|
550
852
|
};
|
|
551
|
-
|
|
552
|
-
|
|
853
|
+
const stopOperationSpec: coreClient.OperationSpec = {
|
|
854
|
+
path:
|
|
855
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.VMwareCloudSimple/virtualMachines/{virtualMachineName}/stop",
|
|
553
856
|
httpMethod: "POST",
|
|
554
|
-
|
|
857
|
+
responses: {
|
|
858
|
+
200: {},
|
|
859
|
+
201: {},
|
|
860
|
+
202: {},
|
|
861
|
+
204: {},
|
|
862
|
+
default: {
|
|
863
|
+
bodyMapper: Mappers.CsrpError,
|
|
864
|
+
headersMapper: Mappers.VirtualMachinesStopExceptionHeaders
|
|
865
|
+
}
|
|
866
|
+
},
|
|
867
|
+
requestBody: Parameters.m,
|
|
868
|
+
queryParameters: [Parameters.apiVersion, Parameters.mode],
|
|
555
869
|
urlParameters: [
|
|
870
|
+
Parameters.$host,
|
|
556
871
|
Parameters.subscriptionId,
|
|
557
872
|
Parameters.resourceGroupName,
|
|
558
|
-
Parameters.
|
|
559
|
-
],
|
|
560
|
-
queryParameters: [
|
|
561
|
-
Parameters.mode,
|
|
562
|
-
Parameters.apiVersion
|
|
873
|
+
Parameters.virtualMachineName
|
|
563
874
|
],
|
|
564
875
|
headerParameters: [
|
|
876
|
+
Parameters.accept,
|
|
565
877
|
Parameters.referer,
|
|
566
|
-
Parameters.
|
|
878
|
+
Parameters.contentType
|
|
567
879
|
],
|
|
568
|
-
|
|
569
|
-
parameterPath: {
|
|
570
|
-
mode: [
|
|
571
|
-
"options",
|
|
572
|
-
"mode1"
|
|
573
|
-
]
|
|
574
|
-
},
|
|
575
|
-
mapper: Mappers.VirtualMachineStopMode
|
|
576
|
-
},
|
|
577
|
-
responses: {
|
|
578
|
-
200: {
|
|
579
|
-
headersMapper: Mappers.VirtualMachinesStopHeaders
|
|
580
|
-
},
|
|
581
|
-
202: {
|
|
582
|
-
headersMapper: Mappers.VirtualMachinesStopHeaders
|
|
583
|
-
},
|
|
584
|
-
default: {
|
|
585
|
-
bodyMapper: Mappers.CSRPError
|
|
586
|
-
}
|
|
587
|
-
},
|
|
880
|
+
mediaType: "json",
|
|
588
881
|
serializer
|
|
589
882
|
};
|
|
590
|
-
|
|
591
|
-
const listBySubscriptionNextOperationSpec: msRest.OperationSpec = {
|
|
592
|
-
httpMethod: "GET",
|
|
593
|
-
baseUrl: "https://management.azure.com",
|
|
883
|
+
const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = {
|
|
594
884
|
path: "{nextLink}",
|
|
595
|
-
|
|
596
|
-
Parameters.nextPageLink
|
|
597
|
-
],
|
|
598
|
-
headerParameters: [
|
|
599
|
-
Parameters.acceptLanguage
|
|
600
|
-
],
|
|
885
|
+
httpMethod: "GET",
|
|
601
886
|
responses: {
|
|
602
887
|
200: {
|
|
603
888
|
bodyMapper: Mappers.VirtualMachineListResponse
|
|
604
889
|
},
|
|
605
890
|
default: {
|
|
606
|
-
bodyMapper: Mappers.
|
|
891
|
+
bodyMapper: Mappers.CsrpError
|
|
607
892
|
}
|
|
608
893
|
},
|
|
894
|
+
queryParameters: [
|
|
895
|
+
Parameters.apiVersion,
|
|
896
|
+
Parameters.filter,
|
|
897
|
+
Parameters.top,
|
|
898
|
+
Parameters.skipToken
|
|
899
|
+
],
|
|
900
|
+
urlParameters: [
|
|
901
|
+
Parameters.$host,
|
|
902
|
+
Parameters.subscriptionId,
|
|
903
|
+
Parameters.nextLink
|
|
904
|
+
],
|
|
905
|
+
headerParameters: [Parameters.accept],
|
|
609
906
|
serializer
|
|
610
907
|
};
|
|
611
|
-
|
|
612
|
-
const listByResourceGroupNextOperationSpec: msRest.OperationSpec = {
|
|
613
|
-
httpMethod: "GET",
|
|
614
|
-
baseUrl: "https://management.azure.com",
|
|
908
|
+
const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = {
|
|
615
909
|
path: "{nextLink}",
|
|
616
|
-
|
|
617
|
-
Parameters.nextPageLink
|
|
618
|
-
],
|
|
619
|
-
headerParameters: [
|
|
620
|
-
Parameters.acceptLanguage
|
|
621
|
-
],
|
|
910
|
+
httpMethod: "GET",
|
|
622
911
|
responses: {
|
|
623
912
|
200: {
|
|
624
913
|
bodyMapper: Mappers.VirtualMachineListResponse
|
|
625
914
|
},
|
|
626
915
|
default: {
|
|
627
|
-
bodyMapper: Mappers.
|
|
916
|
+
bodyMapper: Mappers.CsrpError
|
|
628
917
|
}
|
|
629
918
|
},
|
|
919
|
+
queryParameters: [
|
|
920
|
+
Parameters.apiVersion,
|
|
921
|
+
Parameters.filter,
|
|
922
|
+
Parameters.top,
|
|
923
|
+
Parameters.skipToken
|
|
924
|
+
],
|
|
925
|
+
urlParameters: [
|
|
926
|
+
Parameters.$host,
|
|
927
|
+
Parameters.subscriptionId,
|
|
928
|
+
Parameters.nextLink,
|
|
929
|
+
Parameters.resourceGroupName
|
|
930
|
+
],
|
|
931
|
+
headerParameters: [Parameters.accept],
|
|
630
932
|
serializer
|
|
631
933
|
};
|