@azure/arm-servicefabricmesh 0.1.0 → 3.0.0-beta.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/CHANGELOG.md +11 -0
- package/LICENSE +21 -0
- package/README.md +75 -73
- package/dist/index.js +5478 -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/models/index.d.ts +1366 -0
- package/dist-esm/src/models/index.d.ts.map +1 -0
- package/dist-esm/src/models/index.js +121 -0
- package/dist-esm/src/models/index.js.map +1 -0
- package/dist-esm/src/models/mappers.d.ts +105 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -0
- package/{esm → dist-esm/src}/models/mappers.js +1264 -1320
- package/dist-esm/src/models/mappers.js.map +1 -0
- package/dist-esm/src/models/parameters.d.ts +25 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -0
- package/{esm → dist-esm/src}/models/parameters.js +104 -62
- package/dist-esm/src/models/parameters.js.map +1 -0
- package/dist-esm/src/operations/application.d.ts +82 -0
- package/dist-esm/src/operations/application.d.ts.map +1 -0
- package/dist-esm/src/operations/application.js +340 -0
- package/dist-esm/src/operations/application.js.map +1 -0
- package/dist-esm/src/operations/codePackage.d.ts +23 -0
- package/dist-esm/src/operations/codePackage.d.ts.map +1 -0
- package/dist-esm/src/operations/codePackage.js +66 -0
- package/dist-esm/src/operations/codePackage.js.map +1 -0
- package/dist-esm/src/operations/gateway.d.ts +83 -0
- package/dist-esm/src/operations/gateway.d.ts.map +1 -0
- package/dist-esm/src/operations/gateway.js +341 -0
- package/dist-esm/src/operations/gateway.js.map +1 -0
- package/{esm → dist-esm/src}/operations/index.d.ts +0 -0
- package/dist-esm/src/operations/index.d.ts.map +1 -0
- package/{esm → dist-esm/src}/operations/index.js +3 -5
- package/dist-esm/src/operations/index.js.map +1 -0
- package/dist-esm/src/operations/network.d.ts +82 -0
- package/dist-esm/src/operations/network.d.ts.map +1 -0
- package/dist-esm/src/operations/network.js +340 -0
- package/dist-esm/src/operations/network.js.map +1 -0
- package/dist-esm/src/operations/operations.d.ts +32 -0
- package/dist-esm/src/operations/operations.d.ts.map +1 -0
- package/dist-esm/src/operations/operations.js +120 -0
- package/dist-esm/src/operations/operations.js.map +1 -0
- package/dist-esm/src/operations/secret.d.ts +81 -0
- package/dist-esm/src/operations/secret.d.ts.map +1 -0
- package/dist-esm/src/operations/secret.js +339 -0
- package/dist-esm/src/operations/secret.js.map +1 -0
- package/dist-esm/src/operations/secretValueOperations.d.ts +81 -0
- package/dist-esm/src/operations/secretValueOperations.d.ts.map +1 -0
- package/dist-esm/src/operations/secretValueOperations.js +303 -0
- package/dist-esm/src/operations/secretValueOperations.js.map +1 -0
- package/dist-esm/src/operations/service.d.ts +49 -0
- package/dist-esm/src/operations/service.d.ts.map +1 -0
- package/dist-esm/src/operations/service.js +177 -0
- package/dist-esm/src/operations/service.js.map +1 -0
- package/dist-esm/src/operations/serviceReplica.d.ts +53 -0
- package/dist-esm/src/operations/serviceReplica.d.ts.map +1 -0
- package/dist-esm/src/operations/serviceReplica.js +196 -0
- package/dist-esm/src/operations/serviceReplica.js.map +1 -0
- package/dist-esm/src/operations/volume.d.ts +81 -0
- package/dist-esm/src/operations/volume.d.ts.map +1 -0
- package/dist-esm/src/operations/volume.js +339 -0
- package/dist-esm/src/operations/volume.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/application.d.ts +44 -0
- package/dist-esm/src/operationsInterfaces/application.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/application.js +9 -0
- package/dist-esm/src/operationsInterfaces/application.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/codePackage.d.ts +15 -0
- package/dist-esm/src/operationsInterfaces/codePackage.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/codePackage.js +9 -0
- package/dist-esm/src/operationsInterfaces/codePackage.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/gateway.d.ts +45 -0
- package/dist-esm/src/operationsInterfaces/gateway.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/gateway.js +9 -0
- package/dist-esm/src/operationsInterfaces/gateway.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts +11 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.js +18 -0
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/network.d.ts +44 -0
- package/dist-esm/src/operationsInterfaces/network.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/network.js +9 -0
- package/dist-esm/src/operationsInterfaces/network.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -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/secret.d.ts +43 -0
- package/dist-esm/src/operationsInterfaces/secret.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/secret.js +9 -0
- package/dist-esm/src/operationsInterfaces/secret.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/secretValueOperations.d.ts +55 -0
- package/dist-esm/src/operationsInterfaces/secretValueOperations.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/secretValueOperations.js +9 -0
- package/dist-esm/src/operationsInterfaces/secretValueOperations.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/service.d.ts +23 -0
- package/dist-esm/src/operationsInterfaces/service.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/service.js +9 -0
- package/dist-esm/src/operationsInterfaces/service.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/serviceReplica.d.ts +25 -0
- package/dist-esm/src/operationsInterfaces/serviceReplica.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/serviceReplica.js +9 -0
- package/dist-esm/src/operationsInterfaces/serviceReplica.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/volume.d.ts +43 -0
- package/dist-esm/src/operationsInterfaces/volume.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/volume.js +9 -0
- package/dist-esm/src/operationsInterfaces/volume.js.map +1 -0
- package/dist-esm/src/serviceFabricMeshManagementClient.d.ts +27 -0
- package/dist-esm/src/serviceFabricMeshManagementClient.d.ts.map +1 -0
- package/dist-esm/src/serviceFabricMeshManagementClient.js +60 -0
- package/dist-esm/src/serviceFabricMeshManagementClient.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 +87 -26
- package/review/arm-servicefabricmesh.api.md +1210 -0
- package/rollup.config.js +184 -27
- package/src/index.ts +12 -0
- package/src/models/index.ts +1603 -0
- package/{lib → src}/models/mappers.ts +1315 -1344
- package/src/models/parameters.ts +250 -0
- package/src/operations/application.ts +418 -0
- package/src/operations/codePackage.ts +88 -0
- package/src/operations/gateway.ts +419 -0
- package/{lib → src}/operations/index.ts +3 -5
- package/src/operations/network.ts +418 -0
- package/src/operations/operations.ts +137 -0
- package/src/operations/secret.ts +417 -0
- package/src/operations/secretValueOperations.ts +403 -0
- package/src/operations/service.ts +241 -0
- package/src/operations/serviceReplica.ts +271 -0
- package/src/operations/volume.ts +417 -0
- package/src/operationsInterfaces/application.ts +80 -0
- package/src/operationsInterfaces/codePackage.ts +33 -0
- package/src/operationsInterfaces/gateway.ts +81 -0
- package/src/operationsInterfaces/index.ts +18 -0
- package/src/operationsInterfaces/network.ts +80 -0
- package/src/operationsInterfaces/operations.ts +22 -0
- package/src/operationsInterfaces/secret.ts +79 -0
- package/src/operationsInterfaces/secretValueOperations.ts +99 -0
- package/src/operationsInterfaces/service.ts +46 -0
- package/src/operationsInterfaces/serviceReplica.ts +50 -0
- package/src/operationsInterfaces/volume.ts +79 -0
- package/src/serviceFabricMeshManagementClient.ts +115 -0
- package/tsconfig.json +20 -7
- package/types/arm-servicefabricmesh.d.ts +1940 -0
- package/types/tsdoc-metadata.json +11 -0
- package/dist/arm-servicefabricmesh.js +0 -5353
- package/dist/arm-servicefabricmesh.js.map +0 -1
- package/dist/arm-servicefabricmesh.min.js +0 -1
- package/dist/arm-servicefabricmesh.min.js.map +0 -1
- package/esm/models/applicationMappers.d.ts +0 -2
- package/esm/models/applicationMappers.d.ts.map +0 -1
- package/esm/models/applicationMappers.js +0 -11
- package/esm/models/applicationMappers.js.map +0 -1
- package/esm/models/codePackageMappers.d.ts +0 -2
- package/esm/models/codePackageMappers.d.ts.map +0 -1
- package/esm/models/codePackageMappers.js +0 -11
- package/esm/models/codePackageMappers.js.map +0 -1
- package/esm/models/gatewayMappers.d.ts +0 -2
- package/esm/models/gatewayMappers.d.ts.map +0 -1
- package/esm/models/gatewayMappers.js +0 -11
- package/esm/models/gatewayMappers.js.map +0 -1
- package/esm/models/index.d.ts +0 -2938
- package/esm/models/index.d.ts.map +0 -1
- package/esm/models/index.js +0 -10
- package/esm/models/index.js.map +0 -1
- package/esm/models/mappers.d.ts +0 -102
- package/esm/models/mappers.d.ts.map +0 -1
- package/esm/models/mappers.js.map +0 -1
- package/esm/models/networkMappers.d.ts +0 -2
- package/esm/models/networkMappers.d.ts.map +0 -1
- package/esm/models/networkMappers.js +0 -11
- package/esm/models/networkMappers.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 -11
- package/esm/models/operationsMappers.js.map +0 -1
- package/esm/models/parameters.d.ts +0 -17
- package/esm/models/parameters.d.ts.map +0 -1
- package/esm/models/parameters.js.map +0 -1
- package/esm/models/secretMappers.d.ts +0 -2
- package/esm/models/secretMappers.d.ts.map +0 -1
- package/esm/models/secretMappers.js +0 -11
- package/esm/models/secretMappers.js.map +0 -1
- package/esm/models/secretValueOperationsMappers.d.ts +0 -2
- package/esm/models/secretValueOperationsMappers.d.ts.map +0 -1
- package/esm/models/secretValueOperationsMappers.js +0 -11
- package/esm/models/secretValueOperationsMappers.js.map +0 -1
- package/esm/models/serviceMappers.d.ts +0 -2
- package/esm/models/serviceMappers.d.ts.map +0 -1
- package/esm/models/serviceMappers.js +0 -11
- package/esm/models/serviceMappers.js.map +0 -1
- package/esm/models/serviceReplicaMappers.d.ts +0 -2
- package/esm/models/serviceReplicaMappers.d.ts.map +0 -1
- package/esm/models/serviceReplicaMappers.js +0 -11
- package/esm/models/serviceReplicaMappers.js.map +0 -1
- package/esm/models/volumeMappers.d.ts +0 -2
- package/esm/models/volumeMappers.d.ts.map +0 -1
- package/esm/models/volumeMappers.js +0 -11
- package/esm/models/volumeMappers.js.map +0 -1
- package/esm/operations/application.d.ts +0 -162
- package/esm/operations/application.d.ts.map +0 -1
- package/esm/operations/application.js +0 -238
- package/esm/operations/application.js.map +0 -1
- package/esm/operations/codePackage.d.ts +0 -44
- package/esm/operations/codePackage.d.ts.map +0 -1
- package/esm/operations/codePackage.js +0 -65
- package/esm/operations/codePackage.js.map +0 -1
- package/esm/operations/gateway.d.ts +0 -163
- package/esm/operations/gateway.d.ts.map +0 -1
- package/esm/operations/gateway.js +0 -238
- package/esm/operations/gateway.js.map +0 -1
- package/esm/operations/index.d.ts.map +0 -1
- package/esm/operations/index.js.map +0 -1
- package/esm/operations/network.d.ts +0 -162
- package/esm/operations/network.d.ts.map +0 -1
- package/esm/operations/network.js +0 -238
- package/esm/operations/network.js.map +0 -1
- package/esm/operations/operations.d.ts +0 -48
- package/esm/operations/operations.d.ts.map +0 -1
- package/esm/operations/operations.js +0 -77
- package/esm/operations/operations.js.map +0 -1
- package/esm/operations/secret.d.ts +0 -162
- package/esm/operations/secret.d.ts.map +0 -1
- package/esm/operations/secret.js +0 -238
- package/esm/operations/secret.js.map +0 -1
- package/esm/operations/secretValueOperations.d.ts +0 -175
- package/esm/operations/secretValueOperations.d.ts.map +0 -1
- package/esm/operations/secretValueOperations.js +0 -226
- package/esm/operations/secretValueOperations.js.map +0 -1
- package/esm/operations/service.d.ts +0 -82
- package/esm/operations/service.d.ts.map +0 -1
- package/esm/operations/service.js +0 -117
- package/esm/operations/service.js.map +0 -1
- package/esm/operations/serviceReplica.d.ts +0 -88
- package/esm/operations/serviceReplica.d.ts.map +0 -1
- package/esm/operations/serviceReplica.js +0 -121
- package/esm/operations/serviceReplica.js.map +0 -1
- package/esm/operations/volume.d.ts +0 -162
- package/esm/operations/volume.d.ts.map +0 -1
- package/esm/operations/volume.js +0 -238
- package/esm/operations/volume.js.map +0 -1
- package/esm/serviceFabricMeshManagementClient.d.ts +0 -27
- package/esm/serviceFabricMeshManagementClient.d.ts.map +0 -1
- package/esm/serviceFabricMeshManagementClient.js +0 -42
- package/esm/serviceFabricMeshManagementClient.js.map +0 -1
- package/esm/serviceFabricMeshManagementClientContext.d.ts +0 -16
- package/esm/serviceFabricMeshManagementClientContext.d.ts.map +0 -1
- package/esm/serviceFabricMeshManagementClientContext.js +0 -56
- package/esm/serviceFabricMeshManagementClientContext.js.map +0 -1
- package/lib/models/applicationMappers.ts +0 -76
- package/lib/models/codePackageMappers.ts +0 -18
- package/lib/models/gatewayMappers.ts +0 -76
- package/lib/models/index.ts +0 -3097
- package/lib/models/networkMappers.ts +0 -76
- package/lib/models/operationsMappers.ts +0 -20
- package/lib/models/parameters.ts +0 -175
- package/lib/models/secretMappers.ts +0 -76
- package/lib/models/secretValueOperationsMappers.ts +0 -77
- package/lib/models/serviceMappers.ts +0 -76
- package/lib/models/serviceReplicaMappers.ts +0 -40
- package/lib/models/volumeMappers.ts +0 -76
- package/lib/operations/application.ts +0 -427
- package/lib/operations/codePackage.ts +0 -104
- package/lib/operations/gateway.ts +0 -428
- package/lib/operations/network.ts +0 -427
- package/lib/operations/operations.ts +0 -125
- package/lib/operations/secret.ts +0 -427
- package/lib/operations/secretValueOperations.ts +0 -423
- package/lib/operations/service.ts +0 -204
- package/lib/operations/serviceReplica.ts +0 -214
- package/lib/operations/volume.ts +0 -427
- package/lib/serviceFabricMeshManagementClient.ts +0 -60
- package/lib/serviceFabricMeshManagementClientContext.ts +0 -62
|
@@ -0,0 +1,418 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
10
|
+
import { Network } from "../operationsInterfaces";
|
|
11
|
+
import * as coreClient from "@azure/core-client";
|
|
12
|
+
import * as Mappers from "../models/mappers";
|
|
13
|
+
import * as Parameters from "../models/parameters";
|
|
14
|
+
import { ServiceFabricMeshManagementClient } from "../serviceFabricMeshManagementClient";
|
|
15
|
+
import {
|
|
16
|
+
NetworkResourceDescription,
|
|
17
|
+
NetworkListByResourceGroupNextOptionalParams,
|
|
18
|
+
NetworkListByResourceGroupOptionalParams,
|
|
19
|
+
NetworkListBySubscriptionNextOptionalParams,
|
|
20
|
+
NetworkListBySubscriptionOptionalParams,
|
|
21
|
+
NetworkCreateOptionalParams,
|
|
22
|
+
NetworkCreateResponse,
|
|
23
|
+
NetworkGetOptionalParams,
|
|
24
|
+
NetworkGetResponse,
|
|
25
|
+
NetworkDeleteOptionalParams,
|
|
26
|
+
NetworkListByResourceGroupResponse,
|
|
27
|
+
NetworkListBySubscriptionResponse,
|
|
28
|
+
NetworkListByResourceGroupNextResponse,
|
|
29
|
+
NetworkListBySubscriptionNextResponse
|
|
30
|
+
} from "../models";
|
|
31
|
+
|
|
32
|
+
/// <reference lib="esnext.asynciterable" />
|
|
33
|
+
/** Class containing Network operations. */
|
|
34
|
+
export class NetworkImpl implements Network {
|
|
35
|
+
private readonly client: ServiceFabricMeshManagementClient;
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Initialize a new instance of the class Network class.
|
|
39
|
+
* @param client Reference to the service client
|
|
40
|
+
*/
|
|
41
|
+
constructor(client: ServiceFabricMeshManagementClient) {
|
|
42
|
+
this.client = client;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Gets the information about all network resources in a given resource group. The information include
|
|
47
|
+
* the description and other properties of the Network.
|
|
48
|
+
* @param resourceGroupName Azure resource group name
|
|
49
|
+
* @param options The options parameters.
|
|
50
|
+
*/
|
|
51
|
+
public listByResourceGroup(
|
|
52
|
+
resourceGroupName: string,
|
|
53
|
+
options?: NetworkListByResourceGroupOptionalParams
|
|
54
|
+
): PagedAsyncIterableIterator<NetworkResourceDescription> {
|
|
55
|
+
const iter = this.listByResourceGroupPagingAll(resourceGroupName, options);
|
|
56
|
+
return {
|
|
57
|
+
next() {
|
|
58
|
+
return iter.next();
|
|
59
|
+
},
|
|
60
|
+
[Symbol.asyncIterator]() {
|
|
61
|
+
return this;
|
|
62
|
+
},
|
|
63
|
+
byPage: () => {
|
|
64
|
+
return this.listByResourceGroupPagingPage(resourceGroupName, options);
|
|
65
|
+
}
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
private async *listByResourceGroupPagingPage(
|
|
70
|
+
resourceGroupName: string,
|
|
71
|
+
options?: NetworkListByResourceGroupOptionalParams
|
|
72
|
+
): AsyncIterableIterator<NetworkResourceDescription[]> {
|
|
73
|
+
let result = await this._listByResourceGroup(resourceGroupName, options);
|
|
74
|
+
yield result.value || [];
|
|
75
|
+
let continuationToken = result.nextLink;
|
|
76
|
+
while (continuationToken) {
|
|
77
|
+
result = await this._listByResourceGroupNext(
|
|
78
|
+
resourceGroupName,
|
|
79
|
+
continuationToken,
|
|
80
|
+
options
|
|
81
|
+
);
|
|
82
|
+
continuationToken = result.nextLink;
|
|
83
|
+
yield result.value || [];
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
private async *listByResourceGroupPagingAll(
|
|
88
|
+
resourceGroupName: string,
|
|
89
|
+
options?: NetworkListByResourceGroupOptionalParams
|
|
90
|
+
): AsyncIterableIterator<NetworkResourceDescription> {
|
|
91
|
+
for await (const page of this.listByResourceGroupPagingPage(
|
|
92
|
+
resourceGroupName,
|
|
93
|
+
options
|
|
94
|
+
)) {
|
|
95
|
+
yield* page;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* Gets the information about all network resources in a given resource group. The information include
|
|
101
|
+
* the description and other properties of the network.
|
|
102
|
+
* @param options The options parameters.
|
|
103
|
+
*/
|
|
104
|
+
public listBySubscription(
|
|
105
|
+
options?: NetworkListBySubscriptionOptionalParams
|
|
106
|
+
): PagedAsyncIterableIterator<NetworkResourceDescription> {
|
|
107
|
+
const iter = this.listBySubscriptionPagingAll(options);
|
|
108
|
+
return {
|
|
109
|
+
next() {
|
|
110
|
+
return iter.next();
|
|
111
|
+
},
|
|
112
|
+
[Symbol.asyncIterator]() {
|
|
113
|
+
return this;
|
|
114
|
+
},
|
|
115
|
+
byPage: () => {
|
|
116
|
+
return this.listBySubscriptionPagingPage(options);
|
|
117
|
+
}
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
private async *listBySubscriptionPagingPage(
|
|
122
|
+
options?: NetworkListBySubscriptionOptionalParams
|
|
123
|
+
): AsyncIterableIterator<NetworkResourceDescription[]> {
|
|
124
|
+
let result = await this._listBySubscription(options);
|
|
125
|
+
yield result.value || [];
|
|
126
|
+
let continuationToken = result.nextLink;
|
|
127
|
+
while (continuationToken) {
|
|
128
|
+
result = await this._listBySubscriptionNext(continuationToken, options);
|
|
129
|
+
continuationToken = result.nextLink;
|
|
130
|
+
yield result.value || [];
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
private async *listBySubscriptionPagingAll(
|
|
135
|
+
options?: NetworkListBySubscriptionOptionalParams
|
|
136
|
+
): AsyncIterableIterator<NetworkResourceDescription> {
|
|
137
|
+
for await (const page of this.listBySubscriptionPagingPage(options)) {
|
|
138
|
+
yield* page;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
/**
|
|
143
|
+
* Creates a network resource with the specified name, description and properties. If a network
|
|
144
|
+
* resource with the same name exists, then it is updated with the specified description and
|
|
145
|
+
* properties.
|
|
146
|
+
* @param resourceGroupName Azure resource group name
|
|
147
|
+
* @param networkResourceName The identity of the network.
|
|
148
|
+
* @param networkResourceDescription Description for creating a Network resource.
|
|
149
|
+
* @param options The options parameters.
|
|
150
|
+
*/
|
|
151
|
+
create(
|
|
152
|
+
resourceGroupName: string,
|
|
153
|
+
networkResourceName: string,
|
|
154
|
+
networkResourceDescription: NetworkResourceDescription,
|
|
155
|
+
options?: NetworkCreateOptionalParams
|
|
156
|
+
): Promise<NetworkCreateResponse> {
|
|
157
|
+
return this.client.sendOperationRequest(
|
|
158
|
+
{
|
|
159
|
+
resourceGroupName,
|
|
160
|
+
networkResourceName,
|
|
161
|
+
networkResourceDescription,
|
|
162
|
+
options
|
|
163
|
+
},
|
|
164
|
+
createOperationSpec
|
|
165
|
+
);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/**
|
|
169
|
+
* Gets the information about the network resource with the given name. The information include the
|
|
170
|
+
* description and other properties of the network.
|
|
171
|
+
* @param resourceGroupName Azure resource group name
|
|
172
|
+
* @param networkResourceName The identity of the network.
|
|
173
|
+
* @param options The options parameters.
|
|
174
|
+
*/
|
|
175
|
+
get(
|
|
176
|
+
resourceGroupName: string,
|
|
177
|
+
networkResourceName: string,
|
|
178
|
+
options?: NetworkGetOptionalParams
|
|
179
|
+
): Promise<NetworkGetResponse> {
|
|
180
|
+
return this.client.sendOperationRequest(
|
|
181
|
+
{ resourceGroupName, networkResourceName, options },
|
|
182
|
+
getOperationSpec
|
|
183
|
+
);
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Deletes the network resource identified by the name.
|
|
188
|
+
* @param resourceGroupName Azure resource group name
|
|
189
|
+
* @param networkResourceName The identity of the network.
|
|
190
|
+
* @param options The options parameters.
|
|
191
|
+
*/
|
|
192
|
+
delete(
|
|
193
|
+
resourceGroupName: string,
|
|
194
|
+
networkResourceName: string,
|
|
195
|
+
options?: NetworkDeleteOptionalParams
|
|
196
|
+
): Promise<void> {
|
|
197
|
+
return this.client.sendOperationRequest(
|
|
198
|
+
{ resourceGroupName, networkResourceName, options },
|
|
199
|
+
deleteOperationSpec
|
|
200
|
+
);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
/**
|
|
204
|
+
* Gets the information about all network resources in a given resource group. The information include
|
|
205
|
+
* the description and other properties of the Network.
|
|
206
|
+
* @param resourceGroupName Azure resource group name
|
|
207
|
+
* @param options The options parameters.
|
|
208
|
+
*/
|
|
209
|
+
private _listByResourceGroup(
|
|
210
|
+
resourceGroupName: string,
|
|
211
|
+
options?: NetworkListByResourceGroupOptionalParams
|
|
212
|
+
): Promise<NetworkListByResourceGroupResponse> {
|
|
213
|
+
return this.client.sendOperationRequest(
|
|
214
|
+
{ resourceGroupName, options },
|
|
215
|
+
listByResourceGroupOperationSpec
|
|
216
|
+
);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
/**
|
|
220
|
+
* Gets the information about all network resources in a given resource group. The information include
|
|
221
|
+
* the description and other properties of the network.
|
|
222
|
+
* @param options The options parameters.
|
|
223
|
+
*/
|
|
224
|
+
private _listBySubscription(
|
|
225
|
+
options?: NetworkListBySubscriptionOptionalParams
|
|
226
|
+
): Promise<NetworkListBySubscriptionResponse> {
|
|
227
|
+
return this.client.sendOperationRequest(
|
|
228
|
+
{ options },
|
|
229
|
+
listBySubscriptionOperationSpec
|
|
230
|
+
);
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
/**
|
|
234
|
+
* ListByResourceGroupNext
|
|
235
|
+
* @param resourceGroupName Azure resource group name
|
|
236
|
+
* @param nextLink The nextLink from the previous successful call to the ListByResourceGroup method.
|
|
237
|
+
* @param options The options parameters.
|
|
238
|
+
*/
|
|
239
|
+
private _listByResourceGroupNext(
|
|
240
|
+
resourceGroupName: string,
|
|
241
|
+
nextLink: string,
|
|
242
|
+
options?: NetworkListByResourceGroupNextOptionalParams
|
|
243
|
+
): Promise<NetworkListByResourceGroupNextResponse> {
|
|
244
|
+
return this.client.sendOperationRequest(
|
|
245
|
+
{ resourceGroupName, nextLink, options },
|
|
246
|
+
listByResourceGroupNextOperationSpec
|
|
247
|
+
);
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
/**
|
|
251
|
+
* ListBySubscriptionNext
|
|
252
|
+
* @param nextLink The nextLink from the previous successful call to the ListBySubscription method.
|
|
253
|
+
* @param options The options parameters.
|
|
254
|
+
*/
|
|
255
|
+
private _listBySubscriptionNext(
|
|
256
|
+
nextLink: string,
|
|
257
|
+
options?: NetworkListBySubscriptionNextOptionalParams
|
|
258
|
+
): Promise<NetworkListBySubscriptionNextResponse> {
|
|
259
|
+
return this.client.sendOperationRequest(
|
|
260
|
+
{ nextLink, options },
|
|
261
|
+
listBySubscriptionNextOperationSpec
|
|
262
|
+
);
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
// Operation Specifications
|
|
266
|
+
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
|
267
|
+
|
|
268
|
+
const createOperationSpec: coreClient.OperationSpec = {
|
|
269
|
+
path:
|
|
270
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceFabricMesh/networks/{networkResourceName}",
|
|
271
|
+
httpMethod: "PUT",
|
|
272
|
+
responses: {
|
|
273
|
+
200: {
|
|
274
|
+
bodyMapper: Mappers.NetworkResourceDescription
|
|
275
|
+
},
|
|
276
|
+
201: {
|
|
277
|
+
bodyMapper: Mappers.NetworkResourceDescription
|
|
278
|
+
},
|
|
279
|
+
202: {},
|
|
280
|
+
default: {
|
|
281
|
+
bodyMapper: Mappers.ErrorModel
|
|
282
|
+
}
|
|
283
|
+
},
|
|
284
|
+
requestBody: Parameters.networkResourceDescription,
|
|
285
|
+
queryParameters: [Parameters.apiVersion],
|
|
286
|
+
urlParameters: [
|
|
287
|
+
Parameters.$host,
|
|
288
|
+
Parameters.subscriptionId,
|
|
289
|
+
Parameters.resourceGroupName,
|
|
290
|
+
Parameters.networkResourceName
|
|
291
|
+
],
|
|
292
|
+
headerParameters: [Parameters.accept, Parameters.contentType],
|
|
293
|
+
mediaType: "json",
|
|
294
|
+
serializer
|
|
295
|
+
};
|
|
296
|
+
const getOperationSpec: coreClient.OperationSpec = {
|
|
297
|
+
path:
|
|
298
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceFabricMesh/networks/{networkResourceName}",
|
|
299
|
+
httpMethod: "GET",
|
|
300
|
+
responses: {
|
|
301
|
+
200: {
|
|
302
|
+
bodyMapper: Mappers.NetworkResourceDescription
|
|
303
|
+
},
|
|
304
|
+
default: {
|
|
305
|
+
bodyMapper: Mappers.ErrorModel
|
|
306
|
+
}
|
|
307
|
+
},
|
|
308
|
+
queryParameters: [Parameters.apiVersion],
|
|
309
|
+
urlParameters: [
|
|
310
|
+
Parameters.$host,
|
|
311
|
+
Parameters.subscriptionId,
|
|
312
|
+
Parameters.resourceGroupName,
|
|
313
|
+
Parameters.networkResourceName
|
|
314
|
+
],
|
|
315
|
+
headerParameters: [Parameters.accept],
|
|
316
|
+
serializer
|
|
317
|
+
};
|
|
318
|
+
const deleteOperationSpec: coreClient.OperationSpec = {
|
|
319
|
+
path:
|
|
320
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceFabricMesh/networks/{networkResourceName}",
|
|
321
|
+
httpMethod: "DELETE",
|
|
322
|
+
responses: {
|
|
323
|
+
200: {},
|
|
324
|
+
202: {},
|
|
325
|
+
204: {},
|
|
326
|
+
default: {
|
|
327
|
+
bodyMapper: Mappers.ErrorModel
|
|
328
|
+
}
|
|
329
|
+
},
|
|
330
|
+
queryParameters: [Parameters.apiVersion],
|
|
331
|
+
urlParameters: [
|
|
332
|
+
Parameters.$host,
|
|
333
|
+
Parameters.subscriptionId,
|
|
334
|
+
Parameters.resourceGroupName,
|
|
335
|
+
Parameters.networkResourceName
|
|
336
|
+
],
|
|
337
|
+
headerParameters: [Parameters.accept],
|
|
338
|
+
serializer
|
|
339
|
+
};
|
|
340
|
+
const listByResourceGroupOperationSpec: coreClient.OperationSpec = {
|
|
341
|
+
path:
|
|
342
|
+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceFabricMesh/networks",
|
|
343
|
+
httpMethod: "GET",
|
|
344
|
+
responses: {
|
|
345
|
+
200: {
|
|
346
|
+
bodyMapper: Mappers.NetworkResourceDescriptionList
|
|
347
|
+
},
|
|
348
|
+
default: {
|
|
349
|
+
bodyMapper: Mappers.ErrorModel
|
|
350
|
+
}
|
|
351
|
+
},
|
|
352
|
+
queryParameters: [Parameters.apiVersion],
|
|
353
|
+
urlParameters: [
|
|
354
|
+
Parameters.$host,
|
|
355
|
+
Parameters.subscriptionId,
|
|
356
|
+
Parameters.resourceGroupName
|
|
357
|
+
],
|
|
358
|
+
headerParameters: [Parameters.accept],
|
|
359
|
+
serializer
|
|
360
|
+
};
|
|
361
|
+
const listBySubscriptionOperationSpec: coreClient.OperationSpec = {
|
|
362
|
+
path:
|
|
363
|
+
"/subscriptions/{subscriptionId}/providers/Microsoft.ServiceFabricMesh/networks",
|
|
364
|
+
httpMethod: "GET",
|
|
365
|
+
responses: {
|
|
366
|
+
200: {
|
|
367
|
+
bodyMapper: Mappers.NetworkResourceDescriptionList
|
|
368
|
+
},
|
|
369
|
+
default: {
|
|
370
|
+
bodyMapper: Mappers.ErrorModel
|
|
371
|
+
}
|
|
372
|
+
},
|
|
373
|
+
queryParameters: [Parameters.apiVersion],
|
|
374
|
+
urlParameters: [Parameters.$host, Parameters.subscriptionId],
|
|
375
|
+
headerParameters: [Parameters.accept],
|
|
376
|
+
serializer
|
|
377
|
+
};
|
|
378
|
+
const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = {
|
|
379
|
+
path: "{nextLink}",
|
|
380
|
+
httpMethod: "GET",
|
|
381
|
+
responses: {
|
|
382
|
+
200: {
|
|
383
|
+
bodyMapper: Mappers.NetworkResourceDescriptionList
|
|
384
|
+
},
|
|
385
|
+
default: {
|
|
386
|
+
bodyMapper: Mappers.ErrorModel
|
|
387
|
+
}
|
|
388
|
+
},
|
|
389
|
+
queryParameters: [Parameters.apiVersion],
|
|
390
|
+
urlParameters: [
|
|
391
|
+
Parameters.$host,
|
|
392
|
+
Parameters.nextLink,
|
|
393
|
+
Parameters.subscriptionId,
|
|
394
|
+
Parameters.resourceGroupName
|
|
395
|
+
],
|
|
396
|
+
headerParameters: [Parameters.accept],
|
|
397
|
+
serializer
|
|
398
|
+
};
|
|
399
|
+
const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = {
|
|
400
|
+
path: "{nextLink}",
|
|
401
|
+
httpMethod: "GET",
|
|
402
|
+
responses: {
|
|
403
|
+
200: {
|
|
404
|
+
bodyMapper: Mappers.NetworkResourceDescriptionList
|
|
405
|
+
},
|
|
406
|
+
default: {
|
|
407
|
+
bodyMapper: Mappers.ErrorModel
|
|
408
|
+
}
|
|
409
|
+
},
|
|
410
|
+
queryParameters: [Parameters.apiVersion],
|
|
411
|
+
urlParameters: [
|
|
412
|
+
Parameters.$host,
|
|
413
|
+
Parameters.nextLink,
|
|
414
|
+
Parameters.subscriptionId
|
|
415
|
+
],
|
|
416
|
+
headerParameters: [Parameters.accept],
|
|
417
|
+
serializer
|
|
418
|
+
};
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
10
|
+
import { Operations } from "../operationsInterfaces";
|
|
11
|
+
import * as coreClient from "@azure/core-client";
|
|
12
|
+
import * as Mappers from "../models/mappers";
|
|
13
|
+
import * as Parameters from "../models/parameters";
|
|
14
|
+
import { ServiceFabricMeshManagementClient } from "../serviceFabricMeshManagementClient";
|
|
15
|
+
import {
|
|
16
|
+
OperationResult,
|
|
17
|
+
OperationsListNextOptionalParams,
|
|
18
|
+
OperationsListOptionalParams,
|
|
19
|
+
OperationsListResponse,
|
|
20
|
+
OperationsListNextResponse
|
|
21
|
+
} from "../models";
|
|
22
|
+
|
|
23
|
+
/// <reference lib="esnext.asynciterable" />
|
|
24
|
+
/** Class containing Operations operations. */
|
|
25
|
+
export class OperationsImpl implements Operations {
|
|
26
|
+
private readonly client: ServiceFabricMeshManagementClient;
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Initialize a new instance of the class Operations class.
|
|
30
|
+
* @param client Reference to the service client
|
|
31
|
+
*/
|
|
32
|
+
constructor(client: ServiceFabricMeshManagementClient) {
|
|
33
|
+
this.client = client;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* Lists all the available operations provided by Service Fabric SeaBreeze resource provider.
|
|
38
|
+
* @param options The options parameters.
|
|
39
|
+
*/
|
|
40
|
+
public list(
|
|
41
|
+
options?: OperationsListOptionalParams
|
|
42
|
+
): PagedAsyncIterableIterator<OperationResult> {
|
|
43
|
+
const iter = this.listPagingAll(options);
|
|
44
|
+
return {
|
|
45
|
+
next() {
|
|
46
|
+
return iter.next();
|
|
47
|
+
},
|
|
48
|
+
[Symbol.asyncIterator]() {
|
|
49
|
+
return this;
|
|
50
|
+
},
|
|
51
|
+
byPage: () => {
|
|
52
|
+
return this.listPagingPage(options);
|
|
53
|
+
}
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
private async *listPagingPage(
|
|
58
|
+
options?: OperationsListOptionalParams
|
|
59
|
+
): AsyncIterableIterator<OperationResult[]> {
|
|
60
|
+
let result = await this._list(options);
|
|
61
|
+
yield result.value || [];
|
|
62
|
+
let continuationToken = result.nextLink;
|
|
63
|
+
while (continuationToken) {
|
|
64
|
+
result = await this._listNext(continuationToken, options);
|
|
65
|
+
continuationToken = result.nextLink;
|
|
66
|
+
yield result.value || [];
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
private async *listPagingAll(
|
|
71
|
+
options?: OperationsListOptionalParams
|
|
72
|
+
): AsyncIterableIterator<OperationResult> {
|
|
73
|
+
for await (const page of this.listPagingPage(options)) {
|
|
74
|
+
yield* page;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Lists all the available operations provided by Service Fabric SeaBreeze resource provider.
|
|
80
|
+
* @param options The options parameters.
|
|
81
|
+
*/
|
|
82
|
+
private _list(
|
|
83
|
+
options?: OperationsListOptionalParams
|
|
84
|
+
): Promise<OperationsListResponse> {
|
|
85
|
+
return this.client.sendOperationRequest({ options }, listOperationSpec);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* ListNext
|
|
90
|
+
* @param nextLink The nextLink from the previous successful call to the List method.
|
|
91
|
+
* @param options The options parameters.
|
|
92
|
+
*/
|
|
93
|
+
private _listNext(
|
|
94
|
+
nextLink: string,
|
|
95
|
+
options?: OperationsListNextOptionalParams
|
|
96
|
+
): Promise<OperationsListNextResponse> {
|
|
97
|
+
return this.client.sendOperationRequest(
|
|
98
|
+
{ nextLink, options },
|
|
99
|
+
listNextOperationSpec
|
|
100
|
+
);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
// Operation Specifications
|
|
104
|
+
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
|
105
|
+
|
|
106
|
+
const listOperationSpec: coreClient.OperationSpec = {
|
|
107
|
+
path: "/providers/Microsoft.ServiceFabricMesh/operations",
|
|
108
|
+
httpMethod: "GET",
|
|
109
|
+
responses: {
|
|
110
|
+
200: {
|
|
111
|
+
bodyMapper: Mappers.OperationListResult
|
|
112
|
+
},
|
|
113
|
+
default: {
|
|
114
|
+
bodyMapper: Mappers.ErrorModel
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
queryParameters: [Parameters.apiVersion],
|
|
118
|
+
urlParameters: [Parameters.$host],
|
|
119
|
+
headerParameters: [Parameters.accept],
|
|
120
|
+
serializer
|
|
121
|
+
};
|
|
122
|
+
const listNextOperationSpec: coreClient.OperationSpec = {
|
|
123
|
+
path: "{nextLink}",
|
|
124
|
+
httpMethod: "GET",
|
|
125
|
+
responses: {
|
|
126
|
+
200: {
|
|
127
|
+
bodyMapper: Mappers.OperationListResult
|
|
128
|
+
},
|
|
129
|
+
default: {
|
|
130
|
+
bodyMapper: Mappers.ErrorModel
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
queryParameters: [Parameters.apiVersion],
|
|
134
|
+
urlParameters: [Parameters.$host, Parameters.nextLink],
|
|
135
|
+
headerParameters: [Parameters.accept],
|
|
136
|
+
serializer
|
|
137
|
+
};
|