@azure/arm-datalake-analytics 2.0.0-beta.3 → 2.0.0-beta.4
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 +2 -2
- package/README.md +1 -1
- package/dist/index.js +237 -75
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist-esm/src/dataLakeAnalyticsAccountManagementClient.d.ts +2 -0
- package/dist-esm/src/dataLakeAnalyticsAccountManagementClient.d.ts.map +1 -1
- package/dist-esm/src/dataLakeAnalyticsAccountManagementClient.js +49 -18
- package/dist-esm/src/dataLakeAnalyticsAccountManagementClient.js.map +1 -1
- package/dist-esm/src/index.d.ts +1 -0
- package/dist-esm/src/index.d.ts.map +1 -1
- package/dist-esm/src/index.js +1 -0
- package/dist-esm/src/index.js.map +1 -1
- package/dist-esm/src/models/index.d.ts +31 -20
- package/dist-esm/src/models/index.d.ts.map +1 -1
- package/dist-esm/src/models/index.js +11 -0
- package/dist-esm/src/models/index.js.map +1 -1
- package/dist-esm/src/operations/accounts.d.ts.map +1 -1
- package/dist-esm/src/operations/accounts.js +37 -14
- package/dist-esm/src/operations/accounts.js.map +1 -1
- package/dist-esm/src/operations/computePolicies.d.ts.map +1 -1
- package/dist-esm/src/operations/computePolicies.js +19 -7
- package/dist-esm/src/operations/computePolicies.js.map +1 -1
- package/dist-esm/src/operations/dataLakeStoreAccounts.d.ts.map +1 -1
- package/dist-esm/src/operations/dataLakeStoreAccounts.js +19 -7
- package/dist-esm/src/operations/dataLakeStoreAccounts.js.map +1 -1
- package/dist-esm/src/operations/firewallRules.d.ts.map +1 -1
- package/dist-esm/src/operations/firewallRules.js +19 -7
- package/dist-esm/src/operations/firewallRules.js.map +1 -1
- package/dist-esm/src/operations/storageAccounts.d.ts.map +1 -1
- package/dist-esm/src/operations/storageAccounts.js +55 -21
- package/dist-esm/src/operations/storageAccounts.js.map +1 -1
- package/dist-esm/src/pagingHelper.d.ts +13 -0
- package/dist-esm/src/pagingHelper.d.ts.map +1 -0
- package/dist-esm/src/pagingHelper.js +32 -0
- package/dist-esm/src/pagingHelper.js.map +1 -0
- package/dist-esm/test/{sampleTest.d.ts → datalake-analytics_examples.spec.d.ts} +1 -1
- package/dist-esm/test/datalake-analytics_examples.spec.d.ts.map +1 -0
- package/dist-esm/test/datalake-analytics_examples.spec.js +55 -0
- package/dist-esm/test/datalake-analytics_examples.spec.js.map +1 -0
- package/package.json +14 -10
- package/review/arm-datalake-analytics.api.md +68 -76
- package/src/dataLakeAnalyticsAccountManagementClient.ts +60 -20
- package/src/index.ts +1 -0
- package/src/models/index.ts +32 -20
- package/src/operations/accounts.ts +45 -16
- package/src/operations/computePolicies.ts +26 -12
- package/src/operations/dataLakeStoreAccounts.ts +26 -12
- package/src/operations/firewallRules.ts +26 -12
- package/src/operations/storageAccounts.ts +80 -40
- package/src/pagingHelper.ts +39 -0
- package/types/arm-datalake-analytics.d.ts +42 -20
- package/types/tsdoc-metadata.json +1 -1
- package/dist-esm/test/sampleTest.d.ts.map +0 -1
- package/dist-esm/test/sampleTest.js +0 -89
- package/dist-esm/test/sampleTest.js.map +0 -1
|
@@ -8,6 +8,11 @@
|
|
|
8
8
|
|
|
9
9
|
import * as coreClient from "@azure/core-client";
|
|
10
10
|
import * as coreRestPipeline from "@azure/core-rest-pipeline";
|
|
11
|
+
import {
|
|
12
|
+
PipelineRequest,
|
|
13
|
+
PipelineResponse,
|
|
14
|
+
SendRequest
|
|
15
|
+
} from "@azure/core-rest-pipeline";
|
|
11
16
|
import * as coreAuth from "@azure/core-auth";
|
|
12
17
|
import {
|
|
13
18
|
AccountsImpl,
|
|
@@ -62,47 +67,53 @@ export class DataLakeAnalyticsAccountManagementClient extends coreClient.Service
|
|
|
62
67
|
credential: credentials
|
|
63
68
|
};
|
|
64
69
|
|
|
65
|
-
const packageDetails = `azsdk-js-arm-datalake-analytics/2.0.0-beta.
|
|
70
|
+
const packageDetails = `azsdk-js-arm-datalake-analytics/2.0.0-beta.4`;
|
|
66
71
|
const userAgentPrefix =
|
|
67
72
|
options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
|
68
73
|
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
|
69
74
|
: `${packageDetails}`;
|
|
70
75
|
|
|
71
|
-
if (!options.credentialScopes) {
|
|
72
|
-
options.credentialScopes = ["https://management.azure.com/.default"];
|
|
73
|
-
}
|
|
74
76
|
const optionsWithDefaults = {
|
|
75
77
|
...defaults,
|
|
76
78
|
...options,
|
|
77
79
|
userAgentOptions: {
|
|
78
80
|
userAgentPrefix
|
|
79
81
|
},
|
|
80
|
-
|
|
82
|
+
endpoint:
|
|
81
83
|
options.endpoint ?? options.baseUri ?? "https://management.azure.com"
|
|
82
84
|
};
|
|
83
85
|
super(optionsWithDefaults);
|
|
84
86
|
|
|
87
|
+
let bearerTokenAuthenticationPolicyFound: boolean = false;
|
|
85
88
|
if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {
|
|
86
89
|
const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies();
|
|
87
|
-
|
|
90
|
+
bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(
|
|
88
91
|
(pipelinePolicy) =>
|
|
89
92
|
pipelinePolicy.name ===
|
|
90
93
|
coreRestPipeline.bearerTokenAuthenticationPolicyName
|
|
91
94
|
);
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
95
|
+
}
|
|
96
|
+
if (
|
|
97
|
+
!options ||
|
|
98
|
+
!options.pipeline ||
|
|
99
|
+
options.pipeline.getOrderedPolicies().length == 0 ||
|
|
100
|
+
!bearerTokenAuthenticationPolicyFound
|
|
101
|
+
) {
|
|
102
|
+
this.pipeline.removePolicy({
|
|
103
|
+
name: coreRestPipeline.bearerTokenAuthenticationPolicyName
|
|
104
|
+
});
|
|
105
|
+
this.pipeline.addPolicy(
|
|
106
|
+
coreRestPipeline.bearerTokenAuthenticationPolicy({
|
|
107
|
+
credential: credentials,
|
|
108
|
+
scopes:
|
|
109
|
+
optionsWithDefaults.credentialScopes ??
|
|
110
|
+
`${optionsWithDefaults.endpoint}/.default`,
|
|
111
|
+
challengeCallbacks: {
|
|
112
|
+
authorizeRequestOnChallenge:
|
|
113
|
+
coreClient.authorizeRequestOnClaimChallenge
|
|
114
|
+
}
|
|
115
|
+
})
|
|
116
|
+
);
|
|
106
117
|
}
|
|
107
118
|
// Parameter assignments
|
|
108
119
|
this.subscriptionId = subscriptionId;
|
|
@@ -117,6 +128,35 @@ export class DataLakeAnalyticsAccountManagementClient extends coreClient.Service
|
|
|
117
128
|
this.firewallRules = new FirewallRulesImpl(this);
|
|
118
129
|
this.operations = new OperationsImpl(this);
|
|
119
130
|
this.locations = new LocationsImpl(this);
|
|
131
|
+
this.addCustomApiVersionPolicy(options.apiVersion);
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
/** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */
|
|
135
|
+
private addCustomApiVersionPolicy(apiVersion?: string) {
|
|
136
|
+
if (!apiVersion) {
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
const apiVersionPolicy = {
|
|
140
|
+
name: "CustomApiVersionPolicy",
|
|
141
|
+
async sendRequest(
|
|
142
|
+
request: PipelineRequest,
|
|
143
|
+
next: SendRequest
|
|
144
|
+
): Promise<PipelineResponse> {
|
|
145
|
+
const param = request.url.split("?");
|
|
146
|
+
if (param.length > 1) {
|
|
147
|
+
const newParams = param[1].split("&").map((item) => {
|
|
148
|
+
if (item.indexOf("api-version") > -1) {
|
|
149
|
+
return "api-version=" + apiVersion;
|
|
150
|
+
} else {
|
|
151
|
+
return item;
|
|
152
|
+
}
|
|
153
|
+
});
|
|
154
|
+
request.url = param[0] + "?" + newParams.join("&");
|
|
155
|
+
}
|
|
156
|
+
return next(request);
|
|
157
|
+
}
|
|
158
|
+
};
|
|
159
|
+
this.pipeline.addPolicy(apiVersionPolicy);
|
|
120
160
|
}
|
|
121
161
|
|
|
122
162
|
accounts: Accounts;
|
package/src/index.ts
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
/// <reference lib="esnext.asynciterable" />
|
|
10
|
+
export { getContinuationToken } from "./pagingHelper";
|
|
10
11
|
export * from "./models";
|
|
11
12
|
export { DataLakeAnalyticsAccountManagementClient } from "./dataLakeAnalyticsAccountManagementClient";
|
|
12
13
|
export * from "./operationsInterfaces";
|
package/src/models/index.ts
CHANGED
|
@@ -651,7 +651,8 @@ export interface HiveMetastoreListResult {
|
|
|
651
651
|
}
|
|
652
652
|
|
|
653
653
|
/** The account specific properties that are associated with an underlying Data Lake Analytics account. Returned only when retrieving a specific account. */
|
|
654
|
-
export
|
|
654
|
+
export interface DataLakeAnalyticsAccountProperties
|
|
655
|
+
extends DataLakeAnalyticsAccountPropertiesBasic {
|
|
655
656
|
/**
|
|
656
657
|
* The type of the default Data Lake Store account associated with this account.
|
|
657
658
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -748,10 +749,10 @@ export type DataLakeAnalyticsAccountProperties = DataLakeAnalyticsAccountPropert
|
|
|
748
749
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
749
750
|
*/
|
|
750
751
|
readonly debugDataAccessLevel?: DebugDataAccessLevel;
|
|
751
|
-
}
|
|
752
|
+
}
|
|
752
753
|
|
|
753
754
|
/** A Data Lake Analytics account object, containing all information associated with the named Data Lake Analytics account. */
|
|
754
|
-
export
|
|
755
|
+
export interface DataLakeAnalyticsAccountBasic extends Resource {
|
|
755
756
|
/**
|
|
756
757
|
* The unique identifier associated with this Data Lake Analytics account.
|
|
757
758
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -782,10 +783,10 @@ export type DataLakeAnalyticsAccountBasic = Resource & {
|
|
|
782
783
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
783
784
|
*/
|
|
784
785
|
readonly endpoint?: string;
|
|
785
|
-
}
|
|
786
|
+
}
|
|
786
787
|
|
|
787
788
|
/** A Data Lake Analytics account object, containing all information associated with the named Data Lake Analytics account. */
|
|
788
|
-
export
|
|
789
|
+
export interface DataLakeAnalyticsAccount extends Resource {
|
|
789
790
|
/**
|
|
790
791
|
* The unique identifier associated with this Data Lake Analytics account.
|
|
791
792
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -912,28 +913,28 @@ export type DataLakeAnalyticsAccount = Resource & {
|
|
|
912
913
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
913
914
|
*/
|
|
914
915
|
readonly debugDataAccessLevel?: DebugDataAccessLevel;
|
|
915
|
-
}
|
|
916
|
+
}
|
|
916
917
|
|
|
917
918
|
/** Data Lake Store account information. */
|
|
918
|
-
export
|
|
919
|
+
export interface DataLakeStoreAccountInformation extends SubResource {
|
|
919
920
|
/**
|
|
920
921
|
* The optional suffix for the Data Lake Store account.
|
|
921
922
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
922
923
|
*/
|
|
923
924
|
readonly suffix?: string;
|
|
924
|
-
}
|
|
925
|
+
}
|
|
925
926
|
|
|
926
927
|
/** Azure Storage account information. */
|
|
927
|
-
export
|
|
928
|
+
export interface StorageAccountInformation extends SubResource {
|
|
928
929
|
/**
|
|
929
930
|
* The optional suffix for the storage account.
|
|
930
931
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
931
932
|
*/
|
|
932
933
|
readonly suffix?: string;
|
|
933
|
-
}
|
|
934
|
+
}
|
|
934
935
|
|
|
935
936
|
/** Data Lake Analytics compute policy information. */
|
|
936
|
-
export
|
|
937
|
+
export interface ComputePolicy extends SubResource {
|
|
937
938
|
/**
|
|
938
939
|
* The AAD object identifier for the entity to create a policy for.
|
|
939
940
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -954,9 +955,9 @@ export type ComputePolicy = SubResource & {
|
|
|
954
955
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
955
956
|
*/
|
|
956
957
|
readonly minPriorityPerJob?: number;
|
|
957
|
-
}
|
|
958
|
+
}
|
|
958
959
|
|
|
959
|
-
export
|
|
960
|
+
export interface HiveMetastore extends SubResource {
|
|
960
961
|
/**
|
|
961
962
|
* The serverUri for the Hive MetaStore
|
|
962
963
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -987,10 +988,10 @@ export type HiveMetastore = SubResource & {
|
|
|
987
988
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
988
989
|
*/
|
|
989
990
|
readonly nestedResourceProvisioningState?: NestedResourceProvisioningState;
|
|
990
|
-
}
|
|
991
|
+
}
|
|
991
992
|
|
|
992
993
|
/** Data Lake Analytics VirtualNetwork Rule information. */
|
|
993
|
-
export
|
|
994
|
+
export interface VirtualNetworkRule extends SubResource {
|
|
994
995
|
/**
|
|
995
996
|
* The resource identifier for the subnet
|
|
996
997
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -1001,10 +1002,10 @@ export type VirtualNetworkRule = SubResource & {
|
|
|
1001
1002
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
1002
1003
|
*/
|
|
1003
1004
|
readonly virtualNetworkRuleState?: VirtualNetworkRuleState;
|
|
1004
|
-
}
|
|
1005
|
+
}
|
|
1005
1006
|
|
|
1006
1007
|
/** Data Lake Analytics firewall rule information. */
|
|
1007
|
-
export
|
|
1008
|
+
export interface FirewallRule extends SubResource {
|
|
1008
1009
|
/**
|
|
1009
1010
|
* The start IP address for the firewall rule. This can be either ipv4 or ipv6. Start and End should be in the same protocol.
|
|
1010
1011
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
@@ -1015,21 +1016,24 @@ export type FirewallRule = SubResource & {
|
|
|
1015
1016
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
1016
1017
|
*/
|
|
1017
1018
|
readonly endIpAddress?: string;
|
|
1018
|
-
}
|
|
1019
|
+
}
|
|
1019
1020
|
|
|
1020
1021
|
/** Azure Storage blob container information. */
|
|
1021
|
-
export
|
|
1022
|
+
export interface StorageContainer extends SubResource {
|
|
1022
1023
|
/**
|
|
1023
1024
|
* The last modified time of the blob container.
|
|
1024
1025
|
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
1025
1026
|
*/
|
|
1026
1027
|
readonly lastModifiedTime?: Date;
|
|
1027
|
-
}
|
|
1028
|
+
}
|
|
1028
1029
|
|
|
1029
1030
|
/** Known values of {@link AADObjectType} that the service accepts. */
|
|
1030
1031
|
export enum KnownAADObjectType {
|
|
1032
|
+
/** User */
|
|
1031
1033
|
User = "User",
|
|
1034
|
+
/** Group */
|
|
1032
1035
|
Group = "Group",
|
|
1036
|
+
/** ServicePrincipal */
|
|
1033
1037
|
ServicePrincipal = "ServicePrincipal"
|
|
1034
1038
|
}
|
|
1035
1039
|
|
|
@@ -1046,8 +1050,11 @@ export type AADObjectType = string;
|
|
|
1046
1050
|
|
|
1047
1051
|
/** Known values of {@link OperationOrigin} that the service accepts. */
|
|
1048
1052
|
export enum KnownOperationOrigin {
|
|
1053
|
+
/** User */
|
|
1049
1054
|
User = "user",
|
|
1055
|
+
/** System */
|
|
1050
1056
|
System = "system",
|
|
1057
|
+
/** UserSystem */
|
|
1051
1058
|
UserSystem = "user,system"
|
|
1052
1059
|
}
|
|
1053
1060
|
|
|
@@ -1064,10 +1071,15 @@ export type OperationOrigin = string;
|
|
|
1064
1071
|
|
|
1065
1072
|
/** Known values of {@link SubscriptionState} that the service accepts. */
|
|
1066
1073
|
export enum KnownSubscriptionState {
|
|
1074
|
+
/** Registered */
|
|
1067
1075
|
Registered = "Registered",
|
|
1076
|
+
/** Suspended */
|
|
1068
1077
|
Suspended = "Suspended",
|
|
1078
|
+
/** Deleted */
|
|
1069
1079
|
Deleted = "Deleted",
|
|
1080
|
+
/** Unregistered */
|
|
1070
1081
|
Unregistered = "Unregistered",
|
|
1082
|
+
/** Warned */
|
|
1071
1083
|
Warned = "Warned"
|
|
1072
1084
|
}
|
|
1073
1085
|
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
9
|
+
import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging";
|
|
10
|
+
import { setContinuationToken } from "../pagingHelper";
|
|
10
11
|
import { Accounts } from "../operationsInterfaces";
|
|
11
12
|
import * as coreClient from "@azure/core-client";
|
|
12
13
|
import * as Mappers from "../models/mappers";
|
|
@@ -18,9 +19,9 @@ import {
|
|
|
18
19
|
DataLakeAnalyticsAccountBasic,
|
|
19
20
|
AccountsListNextOptionalParams,
|
|
20
21
|
AccountsListOptionalParams,
|
|
22
|
+
AccountsListResponse,
|
|
21
23
|
AccountsListByResourceGroupNextOptionalParams,
|
|
22
24
|
AccountsListByResourceGroupOptionalParams,
|
|
23
|
-
AccountsListResponse,
|
|
24
25
|
AccountsListByResourceGroupResponse,
|
|
25
26
|
CreateDataLakeAnalyticsAccountParameters,
|
|
26
27
|
AccountsCreateOptionalParams,
|
|
@@ -66,22 +67,34 @@ export class AccountsImpl implements Accounts {
|
|
|
66
67
|
[Symbol.asyncIterator]() {
|
|
67
68
|
return this;
|
|
68
69
|
},
|
|
69
|
-
byPage: () => {
|
|
70
|
-
|
|
70
|
+
byPage: (settings?: PageSettings) => {
|
|
71
|
+
if (settings?.maxPageSize) {
|
|
72
|
+
throw new Error("maxPageSize is not supported by this operation.");
|
|
73
|
+
}
|
|
74
|
+
return this.listPagingPage(options, settings);
|
|
71
75
|
}
|
|
72
76
|
};
|
|
73
77
|
}
|
|
74
78
|
|
|
75
79
|
private async *listPagingPage(
|
|
76
|
-
options?: AccountsListOptionalParams
|
|
80
|
+
options?: AccountsListOptionalParams,
|
|
81
|
+
settings?: PageSettings
|
|
77
82
|
): AsyncIterableIterator<DataLakeAnalyticsAccountBasic[]> {
|
|
78
|
-
let result
|
|
79
|
-
|
|
80
|
-
|
|
83
|
+
let result: AccountsListResponse;
|
|
84
|
+
let continuationToken = settings?.continuationToken;
|
|
85
|
+
if (!continuationToken) {
|
|
86
|
+
result = await this._list(options);
|
|
87
|
+
let page = result.value || [];
|
|
88
|
+
continuationToken = result.nextLink;
|
|
89
|
+
setContinuationToken(page, continuationToken);
|
|
90
|
+
yield page;
|
|
91
|
+
}
|
|
81
92
|
while (continuationToken) {
|
|
82
93
|
result = await this._listNext(continuationToken, options);
|
|
83
94
|
continuationToken = result.nextLink;
|
|
84
|
-
|
|
95
|
+
let page = result.value || [];
|
|
96
|
+
setContinuationToken(page, continuationToken);
|
|
97
|
+
yield page;
|
|
85
98
|
}
|
|
86
99
|
}
|
|
87
100
|
|
|
@@ -111,19 +124,33 @@ export class AccountsImpl implements Accounts {
|
|
|
111
124
|
[Symbol.asyncIterator]() {
|
|
112
125
|
return this;
|
|
113
126
|
},
|
|
114
|
-
byPage: () => {
|
|
115
|
-
|
|
127
|
+
byPage: (settings?: PageSettings) => {
|
|
128
|
+
if (settings?.maxPageSize) {
|
|
129
|
+
throw new Error("maxPageSize is not supported by this operation.");
|
|
130
|
+
}
|
|
131
|
+
return this.listByResourceGroupPagingPage(
|
|
132
|
+
resourceGroupName,
|
|
133
|
+
options,
|
|
134
|
+
settings
|
|
135
|
+
);
|
|
116
136
|
}
|
|
117
137
|
};
|
|
118
138
|
}
|
|
119
139
|
|
|
120
140
|
private async *listByResourceGroupPagingPage(
|
|
121
141
|
resourceGroupName: string,
|
|
122
|
-
options?: AccountsListByResourceGroupOptionalParams
|
|
142
|
+
options?: AccountsListByResourceGroupOptionalParams,
|
|
143
|
+
settings?: PageSettings
|
|
123
144
|
): AsyncIterableIterator<DataLakeAnalyticsAccountBasic[]> {
|
|
124
|
-
let result
|
|
125
|
-
|
|
126
|
-
|
|
145
|
+
let result: AccountsListByResourceGroupResponse;
|
|
146
|
+
let continuationToken = settings?.continuationToken;
|
|
147
|
+
if (!continuationToken) {
|
|
148
|
+
result = await this._listByResourceGroup(resourceGroupName, options);
|
|
149
|
+
let page = result.value || [];
|
|
150
|
+
continuationToken = result.nextLink;
|
|
151
|
+
setContinuationToken(page, continuationToken);
|
|
152
|
+
yield page;
|
|
153
|
+
}
|
|
127
154
|
while (continuationToken) {
|
|
128
155
|
result = await this._listByResourceGroupNext(
|
|
129
156
|
resourceGroupName,
|
|
@@ -131,7 +158,9 @@ export class AccountsImpl implements Accounts {
|
|
|
131
158
|
options
|
|
132
159
|
);
|
|
133
160
|
continuationToken = result.nextLink;
|
|
134
|
-
|
|
161
|
+
let page = result.value || [];
|
|
162
|
+
setContinuationToken(page, continuationToken);
|
|
163
|
+
yield page;
|
|
135
164
|
}
|
|
136
165
|
}
|
|
137
166
|
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
9
|
+
import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging";
|
|
10
|
+
import { setContinuationToken } from "../pagingHelper";
|
|
10
11
|
import { ComputePolicies } from "../operationsInterfaces";
|
|
11
12
|
import * as coreClient from "@azure/core-client";
|
|
12
13
|
import * as Mappers from "../models/mappers";
|
|
@@ -65,11 +66,15 @@ export class ComputePoliciesImpl implements ComputePolicies {
|
|
|
65
66
|
[Symbol.asyncIterator]() {
|
|
66
67
|
return this;
|
|
67
68
|
},
|
|
68
|
-
byPage: () => {
|
|
69
|
+
byPage: (settings?: PageSettings) => {
|
|
70
|
+
if (settings?.maxPageSize) {
|
|
71
|
+
throw new Error("maxPageSize is not supported by this operation.");
|
|
72
|
+
}
|
|
69
73
|
return this.listByAccountPagingPage(
|
|
70
74
|
resourceGroupName,
|
|
71
75
|
accountName,
|
|
72
|
-
options
|
|
76
|
+
options,
|
|
77
|
+
settings
|
|
73
78
|
);
|
|
74
79
|
}
|
|
75
80
|
};
|
|
@@ -78,15 +83,22 @@ export class ComputePoliciesImpl implements ComputePolicies {
|
|
|
78
83
|
private async *listByAccountPagingPage(
|
|
79
84
|
resourceGroupName: string,
|
|
80
85
|
accountName: string,
|
|
81
|
-
options?: ComputePoliciesListByAccountOptionalParams
|
|
86
|
+
options?: ComputePoliciesListByAccountOptionalParams,
|
|
87
|
+
settings?: PageSettings
|
|
82
88
|
): AsyncIterableIterator<ComputePolicy[]> {
|
|
83
|
-
let result
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
89
|
+
let result: ComputePoliciesListByAccountResponse;
|
|
90
|
+
let continuationToken = settings?.continuationToken;
|
|
91
|
+
if (!continuationToken) {
|
|
92
|
+
result = await this._listByAccount(
|
|
93
|
+
resourceGroupName,
|
|
94
|
+
accountName,
|
|
95
|
+
options
|
|
96
|
+
);
|
|
97
|
+
let page = result.value || [];
|
|
98
|
+
continuationToken = result.nextLink;
|
|
99
|
+
setContinuationToken(page, continuationToken);
|
|
100
|
+
yield page;
|
|
101
|
+
}
|
|
90
102
|
while (continuationToken) {
|
|
91
103
|
result = await this._listByAccountNext(
|
|
92
104
|
resourceGroupName,
|
|
@@ -95,7 +107,9 @@ export class ComputePoliciesImpl implements ComputePolicies {
|
|
|
95
107
|
options
|
|
96
108
|
);
|
|
97
109
|
continuationToken = result.nextLink;
|
|
98
|
-
|
|
110
|
+
let page = result.value || [];
|
|
111
|
+
setContinuationToken(page, continuationToken);
|
|
112
|
+
yield page;
|
|
99
113
|
}
|
|
100
114
|
}
|
|
101
115
|
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
9
|
+
import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging";
|
|
10
|
+
import { setContinuationToken } from "../pagingHelper";
|
|
10
11
|
import { DataLakeStoreAccounts } from "../operationsInterfaces";
|
|
11
12
|
import * as coreClient from "@azure/core-client";
|
|
12
13
|
import * as Mappers from "../models/mappers";
|
|
@@ -61,11 +62,15 @@ export class DataLakeStoreAccountsImpl implements DataLakeStoreAccounts {
|
|
|
61
62
|
[Symbol.asyncIterator]() {
|
|
62
63
|
return this;
|
|
63
64
|
},
|
|
64
|
-
byPage: () => {
|
|
65
|
+
byPage: (settings?: PageSettings) => {
|
|
66
|
+
if (settings?.maxPageSize) {
|
|
67
|
+
throw new Error("maxPageSize is not supported by this operation.");
|
|
68
|
+
}
|
|
65
69
|
return this.listByAccountPagingPage(
|
|
66
70
|
resourceGroupName,
|
|
67
71
|
accountName,
|
|
68
|
-
options
|
|
72
|
+
options,
|
|
73
|
+
settings
|
|
69
74
|
);
|
|
70
75
|
}
|
|
71
76
|
};
|
|
@@ -74,15 +79,22 @@ export class DataLakeStoreAccountsImpl implements DataLakeStoreAccounts {
|
|
|
74
79
|
private async *listByAccountPagingPage(
|
|
75
80
|
resourceGroupName: string,
|
|
76
81
|
accountName: string,
|
|
77
|
-
options?: DataLakeStoreAccountsListByAccountOptionalParams
|
|
82
|
+
options?: DataLakeStoreAccountsListByAccountOptionalParams,
|
|
83
|
+
settings?: PageSettings
|
|
78
84
|
): AsyncIterableIterator<DataLakeStoreAccountInformation[]> {
|
|
79
|
-
let result
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
85
|
+
let result: DataLakeStoreAccountsListByAccountResponse;
|
|
86
|
+
let continuationToken = settings?.continuationToken;
|
|
87
|
+
if (!continuationToken) {
|
|
88
|
+
result = await this._listByAccount(
|
|
89
|
+
resourceGroupName,
|
|
90
|
+
accountName,
|
|
91
|
+
options
|
|
92
|
+
);
|
|
93
|
+
let page = result.value || [];
|
|
94
|
+
continuationToken = result.nextLink;
|
|
95
|
+
setContinuationToken(page, continuationToken);
|
|
96
|
+
yield page;
|
|
97
|
+
}
|
|
86
98
|
while (continuationToken) {
|
|
87
99
|
result = await this._listByAccountNext(
|
|
88
100
|
resourceGroupName,
|
|
@@ -91,7 +103,9 @@ export class DataLakeStoreAccountsImpl implements DataLakeStoreAccounts {
|
|
|
91
103
|
options
|
|
92
104
|
);
|
|
93
105
|
continuationToken = result.nextLink;
|
|
94
|
-
|
|
106
|
+
let page = result.value || [];
|
|
107
|
+
setContinuationToken(page, continuationToken);
|
|
108
|
+
yield page;
|
|
95
109
|
}
|
|
96
110
|
}
|
|
97
111
|
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
|
-
import { PagedAsyncIterableIterator } from "@azure/core-paging";
|
|
9
|
+
import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging";
|
|
10
|
+
import { setContinuationToken } from "../pagingHelper";
|
|
10
11
|
import { FirewallRules } from "../operationsInterfaces";
|
|
11
12
|
import * as coreClient from "@azure/core-client";
|
|
12
13
|
import * as Mappers from "../models/mappers";
|
|
@@ -64,11 +65,15 @@ export class FirewallRulesImpl implements FirewallRules {
|
|
|
64
65
|
[Symbol.asyncIterator]() {
|
|
65
66
|
return this;
|
|
66
67
|
},
|
|
67
|
-
byPage: () => {
|
|
68
|
+
byPage: (settings?: PageSettings) => {
|
|
69
|
+
if (settings?.maxPageSize) {
|
|
70
|
+
throw new Error("maxPageSize is not supported by this operation.");
|
|
71
|
+
}
|
|
68
72
|
return this.listByAccountPagingPage(
|
|
69
73
|
resourceGroupName,
|
|
70
74
|
accountName,
|
|
71
|
-
options
|
|
75
|
+
options,
|
|
76
|
+
settings
|
|
72
77
|
);
|
|
73
78
|
}
|
|
74
79
|
};
|
|
@@ -77,15 +82,22 @@ export class FirewallRulesImpl implements FirewallRules {
|
|
|
77
82
|
private async *listByAccountPagingPage(
|
|
78
83
|
resourceGroupName: string,
|
|
79
84
|
accountName: string,
|
|
80
|
-
options?: FirewallRulesListByAccountOptionalParams
|
|
85
|
+
options?: FirewallRulesListByAccountOptionalParams,
|
|
86
|
+
settings?: PageSettings
|
|
81
87
|
): AsyncIterableIterator<FirewallRule[]> {
|
|
82
|
-
let result
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
88
|
+
let result: FirewallRulesListByAccountResponse;
|
|
89
|
+
let continuationToken = settings?.continuationToken;
|
|
90
|
+
if (!continuationToken) {
|
|
91
|
+
result = await this._listByAccount(
|
|
92
|
+
resourceGroupName,
|
|
93
|
+
accountName,
|
|
94
|
+
options
|
|
95
|
+
);
|
|
96
|
+
let page = result.value || [];
|
|
97
|
+
continuationToken = result.nextLink;
|
|
98
|
+
setContinuationToken(page, continuationToken);
|
|
99
|
+
yield page;
|
|
100
|
+
}
|
|
89
101
|
while (continuationToken) {
|
|
90
102
|
result = await this._listByAccountNext(
|
|
91
103
|
resourceGroupName,
|
|
@@ -94,7 +106,9 @@ export class FirewallRulesImpl implements FirewallRules {
|
|
|
94
106
|
options
|
|
95
107
|
);
|
|
96
108
|
continuationToken = result.nextLink;
|
|
97
|
-
|
|
109
|
+
let page = result.value || [];
|
|
110
|
+
setContinuationToken(page, continuationToken);
|
|
111
|
+
yield page;
|
|
98
112
|
}
|
|
99
113
|
}
|
|
100
114
|
|