@azure/arm-resources-profile-2020-09-01-hybrid 2.1.1-alpha.20250718.1 → 2.1.1-alpha.20250730.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser/lroImpl.js +11 -3
- package/dist/browser/lroImpl.js.map +1 -1
- package/dist/browser/models/mappers.js +29 -13
- package/dist/browser/models/mappers.js.map +1 -1
- package/dist/browser/operations/deploymentOperations.js +111 -196
- package/dist/browser/operations/deploymentOperations.js.map +1 -1
- package/dist/browser/operations/deployments.js +320 -310
- package/dist/browser/operations/deployments.js.map +1 -1
- package/dist/browser/operations/operations.js +23 -40
- package/dist/browser/operations/operations.js.map +1 -1
- package/dist/browser/operations/providers.js +45 -79
- package/dist/browser/operations/providers.js.map +1 -1
- package/dist/browser/operations/resourceGroups.js +45 -52
- package/dist/browser/operations/resourceGroups.js.map +1 -1
- package/dist/browser/operations/resources.js +133 -127
- package/dist/browser/operations/resources.js.map +1 -1
- package/dist/browser/operations/tagsOperations.js +23 -40
- package/dist/browser/operations/tagsOperations.js.map +1 -1
- package/dist/browser/pagingHelper.js +2 -4
- package/dist/browser/pagingHelper.js.map +1 -1
- package/dist/browser/resourceManagementClient.js +20 -5
- package/dist/browser/resourceManagementClient.js.map +1 -1
- package/dist/commonjs/lroImpl.js +11 -3
- package/dist/commonjs/lroImpl.js.map +1 -1
- package/dist/commonjs/models/mappers.js +29 -13
- package/dist/commonjs/models/mappers.js.map +1 -1
- package/dist/commonjs/operations/deploymentOperations.js +111 -195
- package/dist/commonjs/operations/deploymentOperations.js.map +1 -1
- package/dist/commonjs/operations/deployments.js +320 -309
- package/dist/commonjs/operations/deployments.js.map +1 -1
- package/dist/commonjs/operations/operations.js +23 -39
- package/dist/commonjs/operations/operations.js.map +1 -1
- package/dist/commonjs/operations/providers.js +45 -78
- package/dist/commonjs/operations/providers.js.map +1 -1
- package/dist/commonjs/operations/resourceGroups.js +45 -51
- package/dist/commonjs/operations/resourceGroups.js.map +1 -1
- package/dist/commonjs/operations/resources.js +133 -126
- package/dist/commonjs/operations/resources.js.map +1 -1
- package/dist/commonjs/operations/tagsOperations.js +23 -39
- package/dist/commonjs/operations/tagsOperations.js.map +1 -1
- package/dist/commonjs/pagingHelper.js +2 -4
- package/dist/commonjs/pagingHelper.js.map +1 -1
- package/dist/commonjs/resourceManagementClient.js +20 -5
- package/dist/commonjs/resourceManagementClient.js.map +1 -1
- package/dist/commonjs/tsdoc-metadata.json +11 -11
- package/dist/esm/lroImpl.js +11 -3
- package/dist/esm/lroImpl.js.map +1 -1
- package/dist/esm/models/mappers.js +29 -13
- package/dist/esm/models/mappers.js.map +1 -1
- package/dist/esm/operations/deploymentOperations.js +111 -196
- package/dist/esm/operations/deploymentOperations.js.map +1 -1
- package/dist/esm/operations/deployments.js +320 -310
- package/dist/esm/operations/deployments.js.map +1 -1
- package/dist/esm/operations/operations.js +23 -40
- package/dist/esm/operations/operations.js.map +1 -1
- package/dist/esm/operations/providers.js +45 -79
- package/dist/esm/operations/providers.js.map +1 -1
- package/dist/esm/operations/resourceGroups.js +45 -52
- package/dist/esm/operations/resourceGroups.js.map +1 -1
- package/dist/esm/operations/resources.js +133 -127
- package/dist/esm/operations/resources.js.map +1 -1
- package/dist/esm/operations/tagsOperations.js +23 -40
- package/dist/esm/operations/tagsOperations.js.map +1 -1
- package/dist/esm/pagingHelper.js +2 -4
- package/dist/esm/pagingHelper.js.map +1 -1
- package/dist/esm/resourceManagementClient.js +20 -5
- package/dist/esm/resourceManagementClient.js.map +1 -1
- package/dist/react-native/lroImpl.js +11 -3
- package/dist/react-native/lroImpl.js.map +1 -1
- package/dist/react-native/models/mappers.js +29 -13
- package/dist/react-native/models/mappers.js.map +1 -1
- package/dist/react-native/operations/deploymentOperations.js +111 -196
- package/dist/react-native/operations/deploymentOperations.js.map +1 -1
- package/dist/react-native/operations/deployments.js +320 -310
- package/dist/react-native/operations/deployments.js.map +1 -1
- package/dist/react-native/operations/operations.js +23 -40
- package/dist/react-native/operations/operations.js.map +1 -1
- package/dist/react-native/operations/providers.js +45 -79
- package/dist/react-native/operations/providers.js.map +1 -1
- package/dist/react-native/operations/resourceGroups.js +45 -52
- package/dist/react-native/operations/resourceGroups.js.map +1 -1
- package/dist/react-native/operations/resources.js +133 -127
- package/dist/react-native/operations/resources.js.map +1 -1
- package/dist/react-native/operations/tagsOperations.js +23 -40
- package/dist/react-native/operations/tagsOperations.js.map +1 -1
- package/dist/react-native/pagingHelper.js +2 -4
- package/dist/react-native/pagingHelper.js.map +1 -1
- package/dist/react-native/resourceManagementClient.js +20 -5
- package/dist/react-native/resourceManagementClient.js.map +1 -1
- package/package.json +2 -2
- package/review/arm-resources-profile-2020-09-01-hybrid-node.api.md +1593 -1593
|
@@ -9,6 +9,9 @@ import * as coreClient from "@azure/core-client";
|
|
|
9
9
|
import * as coreRestPipeline from "@azure/core-rest-pipeline";
|
|
10
10
|
import { OperationsImpl, DeploymentsImpl, ProvidersImpl, ResourcesImpl, ResourceGroupsImpl, TagsOperationsImpl, DeploymentOperationsImpl } from "./operations/index.js";
|
|
11
11
|
export class ResourceManagementClient extends coreClient.ServiceClient {
|
|
12
|
+
$host;
|
|
13
|
+
apiVersion;
|
|
14
|
+
subscriptionId;
|
|
12
15
|
/**
|
|
13
16
|
* Initializes a new instance of the ResourceManagementClient class.
|
|
14
17
|
* @param credentials Subscription credentials which uniquely identify client subscription.
|
|
@@ -16,7 +19,6 @@ export class ResourceManagementClient extends coreClient.ServiceClient {
|
|
|
16
19
|
* @param options The parameter options
|
|
17
20
|
*/
|
|
18
21
|
constructor(credentials, subscriptionId, options) {
|
|
19
|
-
var _a, _b, _c;
|
|
20
22
|
if (credentials === undefined) {
|
|
21
23
|
throw new Error("'credentials' cannot be null");
|
|
22
24
|
}
|
|
@@ -35,12 +37,17 @@ export class ResourceManagementClient extends coreClient.ServiceClient {
|
|
|
35
37
|
const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
|
36
38
|
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
|
37
39
|
: `${packageDetails}`;
|
|
38
|
-
const optionsWithDefaults =
|
|
40
|
+
const optionsWithDefaults = {
|
|
41
|
+
...defaults,
|
|
42
|
+
...options,
|
|
43
|
+
userAgentOptions: {
|
|
39
44
|
userAgentPrefix
|
|
40
|
-
},
|
|
45
|
+
},
|
|
46
|
+
endpoint: options.endpoint ?? options.baseUri ?? "https://management.azure.com"
|
|
47
|
+
};
|
|
41
48
|
super(optionsWithDefaults);
|
|
42
49
|
let bearerTokenAuthenticationPolicyFound = false;
|
|
43
|
-
if (
|
|
50
|
+
if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {
|
|
44
51
|
const pipelinePolicies = options.pipeline.getOrderedPolicies();
|
|
45
52
|
bearerTokenAuthenticationPolicyFound = pipelinePolicies.some((pipelinePolicy) => pipelinePolicy.name ===
|
|
46
53
|
coreRestPipeline.bearerTokenAuthenticationPolicyName);
|
|
@@ -54,7 +61,8 @@ export class ResourceManagementClient extends coreClient.ServiceClient {
|
|
|
54
61
|
});
|
|
55
62
|
this.pipeline.addPolicy(coreRestPipeline.bearerTokenAuthenticationPolicy({
|
|
56
63
|
credential: credentials,
|
|
57
|
-
scopes:
|
|
64
|
+
scopes: optionsWithDefaults.credentialScopes ??
|
|
65
|
+
`${optionsWithDefaults.endpoint}/.default`,
|
|
58
66
|
challengeCallbacks: {
|
|
59
67
|
authorizeRequestOnChallenge: coreClient.authorizeRequestOnClaimChallenge
|
|
60
68
|
}
|
|
@@ -99,5 +107,12 @@ export class ResourceManagementClient extends coreClient.ServiceClient {
|
|
|
99
107
|
};
|
|
100
108
|
this.pipeline.addPolicy(apiVersionPolicy);
|
|
101
109
|
}
|
|
110
|
+
operations;
|
|
111
|
+
deployments;
|
|
112
|
+
providers;
|
|
113
|
+
resources;
|
|
114
|
+
resourceGroups;
|
|
115
|
+
tagsOperations;
|
|
116
|
+
deploymentOperations;
|
|
102
117
|
}
|
|
103
118
|
//# sourceMappingURL=resourceManagementClient.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resourceManagementClient.js","sourceRoot":"","sources":["../../src/resourceManagementClient.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AACjD,OAAO,KAAK,gBAAgB,MAAM,2BAA2B,CAAC;AAO9D,OAAO,EACL,cAAc,EACd,eAAe,EACf,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,kBAAkB,EAClB,wBAAwB,EACzB,MAAM,uBAAuB,CAAC;AAY/B,MAAM,OAAO,wBAAyB,SAAQ,UAAU,CAAC,aAAa;
|
|
1
|
+
{"version":3,"file":"resourceManagementClient.js","sourceRoot":"","sources":["../../src/resourceManagementClient.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,UAAU,MAAM,oBAAoB,CAAC;AACjD,OAAO,KAAK,gBAAgB,MAAM,2BAA2B,CAAC;AAO9D,OAAO,EACL,cAAc,EACd,eAAe,EACf,aAAa,EACb,aAAa,EACb,kBAAkB,EAClB,kBAAkB,EAClB,wBAAwB,EACzB,MAAM,uBAAuB,CAAC;AAY/B,MAAM,OAAO,wBAAyB,SAAQ,UAAU,CAAC,aAAa;IACpE,KAAK,CAAS;IACd,UAAU,CAAS;IACnB,cAAc,CAAS;IAEvB;;;;;OAKG;IACH,YACE,WAAqC,EACrC,cAAsB,EACtB,OAAgD;QAEhD,IAAI,WAAW,KAAK,SAAS,EAAE,CAAC;YAC9B,MAAM,IAAI,KAAK,CAAC,8BAA8B,CAAC,CAAC;QAClD,CAAC;QACD,IAAI,cAAc,KAAK,SAAS,EAAE,CAAC;YACjC,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAC;QACrD,CAAC;QAED,0CAA0C;QAC1C,IAAI,CAAC,OAAO,EAAE,CAAC;YACb,OAAO,GAAG,EAAE,CAAC;QACf,CAAC;QACD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AAO,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;gBACrC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;oBACrB,MAAM,SAAS,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;wBACjD,IAAI,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC;4BACrC,OAAO,cAAc,GAAG,UAAU,CAAC;wBACrC,CAAC;6BAAM,CAAC;4BACN,OAAO,IAAI,CAAC;wBACd,CAAC;oBACH,CAAC,CAAC,CAAC;oBACH,OAAO,CAAC,GAAG,GAAG,KAAK,CAAC,CAAC,CAAC,GAAG,GAAG,GAAG,SAAS,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;gBACrD,CAAC;gBACD,OAAO,IAAI,CAAC,OAAO,CAAC,CAAC;YACvB,CAAC;SACF,CAAC;QACF,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAAC;IAC5C,CAAC;IAED,UAAU,CAAa;IACvB,WAAW,CAAc;IACzB,SAAS,CAAY;IACrB,SAAS,CAAY;IACrB,cAAc,CAAiB;IAC/B,cAAc,CAAiB;IAC/B,oBAAoB,CAAuB;CAC5C","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport * as coreClient from \"@azure/core-client\";\nimport * as coreRestPipeline from \"@azure/core-rest-pipeline\";\nimport {\n PipelineRequest,\n PipelineResponse,\n SendRequest\n} from \"@azure/core-rest-pipeline\";\nimport * as coreAuth from \"@azure/core-auth\";\nimport {\n OperationsImpl,\n DeploymentsImpl,\n ProvidersImpl,\n ResourcesImpl,\n ResourceGroupsImpl,\n TagsOperationsImpl,\n DeploymentOperationsImpl\n} from \"./operations/index.js\";\nimport {\n Operations,\n Deployments,\n Providers,\n Resources,\n ResourceGroups,\n TagsOperations,\n DeploymentOperations\n} from \"./operationsInterfaces/index.js\";\nimport { ResourceManagementClientOptionalParams } from \"./models/index.js\";\n\nexport class ResourceManagementClient extends coreClient.ServiceClient {\n $host: string;\n apiVersion: string;\n subscriptionId: string;\n\n /**\n * Initializes a new instance of the ResourceManagementClient class.\n * @param credentials Subscription credentials which uniquely identify client subscription.\n * @param subscriptionId The ID of the target subscription.\n * @param options The parameter options\n */\n constructor(\n credentials: coreAuth.TokenCredential,\n subscriptionId: string,\n options?: ResourceManagementClientOptionalParams\n ) {\n if (credentials === undefined) {\n throw new Error(\"'credentials' cannot be null\");\n }\n if (subscriptionId === undefined) {\n throw new Error(\"'subscriptionId' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: ResourceManagementClientOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\",\n credential: credentials\n };\n\n const packageDetails = `azsdk-js-arm-resources-profile-2020-09-01-hybrid/2.1.1`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix\n },\n endpoint:\n options.endpoint ?? options.baseUri ?? \"https://management.azure.com\"\n };\n super(optionsWithDefaults);\n\n let bearerTokenAuthenticationPolicyFound: boolean = false;\n if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {\n const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies();\n bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(\n (pipelinePolicy) =>\n pipelinePolicy.name ===\n coreRestPipeline.bearerTokenAuthenticationPolicyName\n );\n }\n if (\n !options ||\n !options.pipeline ||\n options.pipeline.getOrderedPolicies().length == 0 ||\n !bearerTokenAuthenticationPolicyFound\n ) {\n this.pipeline.removePolicy({\n name: coreRestPipeline.bearerTokenAuthenticationPolicyName\n });\n this.pipeline.addPolicy(\n coreRestPipeline.bearerTokenAuthenticationPolicy({\n credential: credentials,\n scopes:\n optionsWithDefaults.credentialScopes ??\n `${optionsWithDefaults.endpoint}/.default`,\n challengeCallbacks: {\n authorizeRequestOnChallenge:\n coreClient.authorizeRequestOnClaimChallenge\n }\n })\n );\n }\n // Parameter assignments\n this.subscriptionId = subscriptionId;\n\n // Assigning values to Constant parameters\n this.$host = options.$host || \"https://management.azure.com\";\n this.apiVersion = options.apiVersion || \"2019-10-01\";\n this.operations = new OperationsImpl(this);\n this.deployments = new DeploymentsImpl(this);\n this.providers = new ProvidersImpl(this);\n this.resources = new ResourcesImpl(this);\n this.resourceGroups = new ResourceGroupsImpl(this);\n this.tagsOperations = new TagsOperationsImpl(this);\n this.deploymentOperations = new DeploymentOperationsImpl(this);\n this.addCustomApiVersionPolicy(options.apiVersion);\n }\n\n /** A function that adds a policy that sets the api-version (or equivalent) to reflect the library version. */\n private addCustomApiVersionPolicy(apiVersion?: string) {\n if (!apiVersion) {\n return;\n }\n const apiVersionPolicy = {\n name: \"CustomApiVersionPolicy\",\n async sendRequest(\n request: PipelineRequest,\n next: SendRequest\n ): Promise<PipelineResponse> {\n const param = request.url.split(\"?\");\n if (param.length > 1) {\n const newParams = param[1].split(\"&\").map((item) => {\n if (item.indexOf(\"api-version\") > -1) {\n return \"api-version=\" + apiVersion;\n } else {\n return item;\n }\n });\n request.url = param[0] + \"?\" + newParams.join(\"&\");\n }\n return next(request);\n }\n };\n this.pipeline.addPolicy(apiVersionPolicy);\n }\n\n operations: Operations;\n deployments: Deployments;\n providers: Providers;\n resources: Resources;\n resourceGroups: ResourceGroups;\n tagsOperations: TagsOperations;\n deploymentOperations: DeploymentOperations;\n}\n"]}
|
|
@@ -5,8 +5,12 @@
|
|
|
5
5
|
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
6
|
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
7
|
*/
|
|
8
|
-
import { __rest } from "tslib";
|
|
9
8
|
export class LroImpl {
|
|
9
|
+
sendOperationFn;
|
|
10
|
+
args;
|
|
11
|
+
spec;
|
|
12
|
+
requestPath;
|
|
13
|
+
requestMethod;
|
|
10
14
|
constructor(sendOperationFn, args, spec, requestPath = spec.path, requestMethod = spec.httpMethod) {
|
|
11
15
|
this.sendOperationFn = sendOperationFn;
|
|
12
16
|
this.args = args;
|
|
@@ -18,8 +22,12 @@ export class LroImpl {
|
|
|
18
22
|
return this.sendOperationFn(this.args, this.spec);
|
|
19
23
|
}
|
|
20
24
|
async sendPollRequest(path) {
|
|
21
|
-
const
|
|
22
|
-
return this.sendOperationFn(this.args,
|
|
25
|
+
const { requestBody, ...restSpec } = this.spec;
|
|
26
|
+
return this.sendOperationFn(this.args, {
|
|
27
|
+
...restSpec,
|
|
28
|
+
path,
|
|
29
|
+
httpMethod: "GET"
|
|
30
|
+
});
|
|
23
31
|
}
|
|
24
32
|
}
|
|
25
33
|
//# sourceMappingURL=lroImpl.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lroImpl.js","sourceRoot":"","sources":["../../src/lroImpl.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG
|
|
1
|
+
{"version":3,"file":"lroImpl.js","sourceRoot":"","sources":["../../src/lroImpl.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,MAAM,OAAO,OAAO;IAER;IACA;IACA;IAKD;IACA;IATT,YACU,eAAkE,EAClE,IAA6B,EAC7B,IAIe,EAChB,cAAsB,IAAI,CAAC,IAAK,EAChC,gBAAwB,IAAI,CAAC,UAAU;QARtC,oBAAe,GAAf,eAAe,CAAmD;QAClE,SAAI,GAAJ,IAAI,CAAyB;QAC7B,SAAI,GAAJ,IAAI,CAIW;QAChB,gBAAW,GAAX,WAAW,CAAqB;QAChC,kBAAa,GAAb,aAAa,CAA0B;IAC7C,CAAC;IACG,KAAK,CAAC,kBAAkB;QAC7B,OAAO,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;IACpD,CAAC;IACM,KAAK,CAAC,eAAe,CAAC,IAAY;QACvC,MAAM,EAAE,WAAW,EAAE,GAAG,QAAQ,EAAE,GAAG,IAAI,CAAC,IAAI,CAAC;QAC/C,OAAO,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,EAAE;YACrC,GAAG,QAAQ;YACX,IAAI;YACJ,UAAU,EAAE,KAAK;SAClB,CAAC,CAAC;IACL,CAAC;CACF","sourcesContent":["/*\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n *\n * Code generated by Microsoft (R) AutoRest Code Generator.\n * Changes may cause incorrect behavior and will be lost if the code is regenerated.\n */\n\nimport { LongRunningOperation, LroResponse } from \"@azure/core-lro\";\n\nexport class LroImpl<T> implements LongRunningOperation<T> {\n constructor(\n private sendOperationFn: (args: any, spec: any) => Promise<LroResponse<T>>,\n private args: Record<string, unknown>,\n private spec: {\n readonly requestBody?: unknown;\n readonly path?: string;\n readonly httpMethod: string;\n } & Record<string, any>,\n public requestPath: string = spec.path!,\n public requestMethod: string = spec.httpMethod\n ) {}\n public async sendInitialRequest(): Promise<LroResponse<T>> {\n return this.sendOperationFn(this.args, this.spec);\n }\n public async sendPollRequest(path: string): Promise<LroResponse<T>> {\n const { requestBody, ...restSpec } = this.spec;\n return this.sendOperationFn(this.args, {\n ...restSpec,\n path,\n httpMethod: \"GET\"\n });\n }\n}\n"]}
|
|
@@ -2151,32 +2151,39 @@ export const DeploymentWhatIfProperties = {
|
|
|
2151
2151
|
type: {
|
|
2152
2152
|
name: "Composite",
|
|
2153
2153
|
className: "DeploymentWhatIfProperties",
|
|
2154
|
-
modelProperties:
|
|
2154
|
+
modelProperties: {
|
|
2155
|
+
...DeploymentProperties.type.modelProperties,
|
|
2156
|
+
whatIfSettings: {
|
|
2155
2157
|
serializedName: "whatIfSettings",
|
|
2156
2158
|
type: {
|
|
2157
2159
|
name: "Composite",
|
|
2158
2160
|
className: "DeploymentWhatIfSettings"
|
|
2159
2161
|
}
|
|
2160
|
-
}
|
|
2162
|
+
}
|
|
2163
|
+
}
|
|
2161
2164
|
}
|
|
2162
2165
|
};
|
|
2163
2166
|
export const GenericResource = {
|
|
2164
2167
|
type: {
|
|
2165
2168
|
name: "Composite",
|
|
2166
2169
|
className: "GenericResource",
|
|
2167
|
-
modelProperties:
|
|
2170
|
+
modelProperties: {
|
|
2171
|
+
...Resource.type.modelProperties,
|
|
2172
|
+
plan: {
|
|
2168
2173
|
serializedName: "plan",
|
|
2169
2174
|
type: {
|
|
2170
2175
|
name: "Composite",
|
|
2171
2176
|
className: "Plan"
|
|
2172
2177
|
}
|
|
2173
|
-
},
|
|
2178
|
+
},
|
|
2179
|
+
properties: {
|
|
2174
2180
|
serializedName: "properties",
|
|
2175
2181
|
type: {
|
|
2176
2182
|
name: "Dictionary",
|
|
2177
2183
|
value: { type: { name: "any" } }
|
|
2178
2184
|
}
|
|
2179
|
-
},
|
|
2185
|
+
},
|
|
2186
|
+
kind: {
|
|
2180
2187
|
constraints: {
|
|
2181
2188
|
Pattern: new RegExp("^[-\\w\\._,\\(\\)]+$")
|
|
2182
2189
|
},
|
|
@@ -2184,49 +2191,58 @@ export const GenericResource = {
|
|
|
2184
2191
|
type: {
|
|
2185
2192
|
name: "String"
|
|
2186
2193
|
}
|
|
2187
|
-
},
|
|
2194
|
+
},
|
|
2195
|
+
managedBy: {
|
|
2188
2196
|
serializedName: "managedBy",
|
|
2189
2197
|
type: {
|
|
2190
2198
|
name: "String"
|
|
2191
2199
|
}
|
|
2192
|
-
},
|
|
2200
|
+
},
|
|
2201
|
+
sku: {
|
|
2193
2202
|
serializedName: "sku",
|
|
2194
2203
|
type: {
|
|
2195
2204
|
name: "Composite",
|
|
2196
2205
|
className: "Sku"
|
|
2197
2206
|
}
|
|
2198
|
-
},
|
|
2207
|
+
},
|
|
2208
|
+
identity: {
|
|
2199
2209
|
serializedName: "identity",
|
|
2200
2210
|
type: {
|
|
2201
2211
|
name: "Composite",
|
|
2202
2212
|
className: "Identity"
|
|
2203
2213
|
}
|
|
2204
|
-
}
|
|
2214
|
+
}
|
|
2215
|
+
}
|
|
2205
2216
|
}
|
|
2206
2217
|
};
|
|
2207
2218
|
export const GenericResourceExpanded = {
|
|
2208
2219
|
type: {
|
|
2209
2220
|
name: "Composite",
|
|
2210
2221
|
className: "GenericResourceExpanded",
|
|
2211
|
-
modelProperties:
|
|
2222
|
+
modelProperties: {
|
|
2223
|
+
...GenericResource.type.modelProperties,
|
|
2224
|
+
createdTime: {
|
|
2212
2225
|
serializedName: "createdTime",
|
|
2213
2226
|
readOnly: true,
|
|
2214
2227
|
type: {
|
|
2215
2228
|
name: "DateTime"
|
|
2216
2229
|
}
|
|
2217
|
-
},
|
|
2230
|
+
},
|
|
2231
|
+
changedTime: {
|
|
2218
2232
|
serializedName: "changedTime",
|
|
2219
2233
|
readOnly: true,
|
|
2220
2234
|
type: {
|
|
2221
2235
|
name: "DateTime"
|
|
2222
2236
|
}
|
|
2223
|
-
},
|
|
2237
|
+
},
|
|
2238
|
+
provisioningState: {
|
|
2224
2239
|
serializedName: "provisioningState",
|
|
2225
2240
|
readOnly: true,
|
|
2226
2241
|
type: {
|
|
2227
2242
|
name: "String"
|
|
2228
2243
|
}
|
|
2229
|
-
}
|
|
2244
|
+
}
|
|
2245
|
+
}
|
|
2230
2246
|
}
|
|
2231
2247
|
};
|
|
2232
2248
|
export const DeploymentsWhatIfAtTenantScopeHeaders = {
|