@azure/arm-confidentialledger 1.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 +5 -0
- package/LICENSE +21 -0
- package/README.md +109 -0
- package/dist/index.js +1487 -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/samples-dev/checkNameAvailabilitySample.d.ts +2 -0
- package/dist-esm/samples-dev/checkNameAvailabilitySample.d.ts.map +1 -0
- package/dist-esm/samples-dev/checkNameAvailabilitySample.js +33 -0
- package/dist-esm/samples-dev/checkNameAvailabilitySample.js.map +1 -0
- package/dist-esm/samples-dev/ledgerCreateSample.d.ts +2 -0
- package/dist-esm/samples-dev/ledgerCreateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/ledgerCreateSample.js +51 -0
- package/dist-esm/samples-dev/ledgerCreateSample.js.map +1 -0
- package/dist-esm/samples-dev/ledgerDeleteSample.d.ts +2 -0
- package/dist-esm/samples-dev/ledgerDeleteSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/ledgerDeleteSample.js +31 -0
- package/dist-esm/samples-dev/ledgerDeleteSample.js.map +1 -0
- package/dist-esm/samples-dev/ledgerGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/ledgerGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/ledgerGetSample.js +31 -0
- package/dist-esm/samples-dev/ledgerGetSample.js.map +1 -0
- package/dist-esm/samples-dev/ledgerListByResourceGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/ledgerListByResourceGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/ledgerListByResourceGroupSample.js +44 -0
- package/dist-esm/samples-dev/ledgerListByResourceGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/ledgerListBySubscriptionSample.d.ts +2 -0
- package/dist-esm/samples-dev/ledgerListBySubscriptionSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/ledgerListBySubscriptionSample.js +43 -0
- package/dist-esm/samples-dev/ledgerListBySubscriptionSample.js.map +1 -0
- package/dist-esm/samples-dev/ledgerUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/ledgerUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/ledgerUpdateSample.js +54 -0
- package/dist-esm/samples-dev/ledgerUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/operationsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/operationsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/operationsListSample.js +43 -0
- package/dist-esm/samples-dev/operationsListSample.js.map +1 -0
- package/dist-esm/src/confidentialLedgerClient.d.ts +28 -0
- package/dist-esm/src/confidentialLedgerClient.d.ts.map +1 -0
- package/dist-esm/src/confidentialLedgerClient.js +130 -0
- package/dist-esm/src/confidentialLedgerClient.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 +379 -0
- package/dist-esm/src/models/index.d.ts.map +1 -0
- package/dist-esm/src/models/index.js +47 -0
- package/dist-esm/src/models/index.js.map +1 -0
- package/dist-esm/src/models/mappers.d.ts +19 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -0
- package/dist-esm/src/models/mappers.js +501 -0
- package/dist-esm/src/models/mappers.js.map +1 -0
- package/dist-esm/src/models/parameters.d.ts +13 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -0
- package/dist-esm/src/models/parameters.js +118 -0
- package/dist-esm/src/models/parameters.js.map +1 -0
- package/dist-esm/src/operations/index.d.ts +3 -0
- package/dist-esm/src/operations/index.d.ts.map +1 -0
- package/dist-esm/src/operations/index.js +10 -0
- package/dist-esm/src/operations/index.js.map +1 -0
- package/dist-esm/src/operations/ledger.d.ts +107 -0
- package/dist-esm/src/operations/ledger.d.ts.map +1 -0
- package/dist-esm/src/operations/ledger.js +507 -0
- package/dist-esm/src/operations/ledger.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/operationsInterfaces/index.d.ts +3 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.js +10 -0
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/ledger.d.ts +71 -0
- package/dist-esm/src/operationsInterfaces/ledger.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/ledger.js +9 -0
- package/dist-esm/src/operationsInterfaces/ledger.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/test/sampleTest.d.ts +2 -0
- package/dist-esm/test/sampleTest.d.ts.map +1 -0
- package/dist-esm/test/sampleTest.js +38 -0
- package/dist-esm/test/sampleTest.js.map +1 -0
- package/package.json +122 -0
- package/review/arm-confidentialledger.api.md +333 -0
- package/rollup.config.js +122 -0
- package/src/confidentialLedgerClient.ts +181 -0
- package/src/index.ts +12 -0
- package/src/lroImpl.ts +34 -0
- package/src/models/index.ts +442 -0
- package/src/models/mappers.ts +524 -0
- package/src/models/parameters.ts +137 -0
- package/src/operations/index.ts +10 -0
- package/src/operations/ledger.ts +674 -0
- package/src/operations/operations.ts +137 -0
- package/src/operationsInterfaces/index.ts +10 -0
- package/src/operationsInterfaces/ledger.ts +132 -0
- package/src/operationsInterfaces/operations.ts +25 -0
- package/tsconfig.json +33 -0
- package/types/arm-confidentialledger.d.ts +534 -0
- package/types/tsdoc-metadata.json +11 -0
@@ -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 { ConfidentialLedgerClient } from "../confidentialLedgerClient";
|
15
|
+
import {
|
16
|
+
ResourceProviderOperationDefinition,
|
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: ConfidentialLedgerClient;
|
27
|
+
|
28
|
+
/**
|
29
|
+
* Initialize a new instance of the class Operations class.
|
30
|
+
* @param client Reference to the service client
|
31
|
+
*/
|
32
|
+
constructor(client: ConfidentialLedgerClient) {
|
33
|
+
this.client = client;
|
34
|
+
}
|
35
|
+
|
36
|
+
/**
|
37
|
+
* Retrieves a list of available API operations
|
38
|
+
* @param options The options parameters.
|
39
|
+
*/
|
40
|
+
public list(
|
41
|
+
options?: OperationsListOptionalParams
|
42
|
+
): PagedAsyncIterableIterator<ResourceProviderOperationDefinition> {
|
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<ResourceProviderOperationDefinition[]> {
|
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<ResourceProviderOperationDefinition> {
|
73
|
+
for await (const page of this.listPagingPage(options)) {
|
74
|
+
yield* page;
|
75
|
+
}
|
76
|
+
}
|
77
|
+
|
78
|
+
/**
|
79
|
+
* Retrieves a list of available API operations
|
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.ConfidentialLedger/operations",
|
108
|
+
httpMethod: "GET",
|
109
|
+
responses: {
|
110
|
+
200: {
|
111
|
+
bodyMapper: Mappers.ResourceProviderOperationList
|
112
|
+
},
|
113
|
+
default: {
|
114
|
+
bodyMapper: Mappers.ErrorResponse
|
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.ResourceProviderOperationList
|
128
|
+
},
|
129
|
+
default: {
|
130
|
+
bodyMapper: Mappers.ErrorResponse
|
131
|
+
}
|
132
|
+
},
|
133
|
+
queryParameters: [Parameters.apiVersion],
|
134
|
+
urlParameters: [Parameters.$host, Parameters.nextLink],
|
135
|
+
headerParameters: [Parameters.accept],
|
136
|
+
serializer
|
137
|
+
};
|
@@ -0,0 +1,10 @@
|
|
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
|
+
export * from "./operations";
|
10
|
+
export * from "./ledger";
|
@@ -0,0 +1,132 @@
|
|
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 { PollerLike, PollOperationState } from "@azure/core-lro";
|
11
|
+
import {
|
12
|
+
ConfidentialLedger,
|
13
|
+
LedgerListByResourceGroupOptionalParams,
|
14
|
+
LedgerListBySubscriptionOptionalParams,
|
15
|
+
LedgerGetOptionalParams,
|
16
|
+
LedgerGetResponse,
|
17
|
+
LedgerDeleteOptionalParams,
|
18
|
+
LedgerCreateOptionalParams,
|
19
|
+
LedgerCreateResponse,
|
20
|
+
LedgerUpdateOptionalParams,
|
21
|
+
LedgerUpdateResponse
|
22
|
+
} from "../models";
|
23
|
+
|
24
|
+
/// <reference lib="esnext.asynciterable" />
|
25
|
+
/** Interface representing a Ledger. */
|
26
|
+
export interface Ledger {
|
27
|
+
/**
|
28
|
+
* Retrieves the properties of all Confidential Ledgers.
|
29
|
+
* @param resourceGroupName The name of the resource group.
|
30
|
+
* @param options The options parameters.
|
31
|
+
*/
|
32
|
+
listByResourceGroup(
|
33
|
+
resourceGroupName: string,
|
34
|
+
options?: LedgerListByResourceGroupOptionalParams
|
35
|
+
): PagedAsyncIterableIterator<ConfidentialLedger>;
|
36
|
+
/**
|
37
|
+
* Retrieves the properties of all Confidential Ledgers.
|
38
|
+
* @param options The options parameters.
|
39
|
+
*/
|
40
|
+
listBySubscription(
|
41
|
+
options?: LedgerListBySubscriptionOptionalParams
|
42
|
+
): PagedAsyncIterableIterator<ConfidentialLedger>;
|
43
|
+
/**
|
44
|
+
* Retrieves the properties of a Confidential Ledger.
|
45
|
+
* @param resourceGroupName The name of the resource group.
|
46
|
+
* @param ledgerName Name of the Confidential Ledger
|
47
|
+
* @param options The options parameters.
|
48
|
+
*/
|
49
|
+
get(
|
50
|
+
resourceGroupName: string,
|
51
|
+
ledgerName: string,
|
52
|
+
options?: LedgerGetOptionalParams
|
53
|
+
): Promise<LedgerGetResponse>;
|
54
|
+
/**
|
55
|
+
* Deletes an existing Confidential Ledger.
|
56
|
+
* @param resourceGroupName The name of the resource group.
|
57
|
+
* @param ledgerName Name of the Confidential Ledger
|
58
|
+
* @param options The options parameters.
|
59
|
+
*/
|
60
|
+
beginDelete(
|
61
|
+
resourceGroupName: string,
|
62
|
+
ledgerName: string,
|
63
|
+
options?: LedgerDeleteOptionalParams
|
64
|
+
): Promise<PollerLike<PollOperationState<void>, void>>;
|
65
|
+
/**
|
66
|
+
* Deletes an existing Confidential Ledger.
|
67
|
+
* @param resourceGroupName The name of the resource group.
|
68
|
+
* @param ledgerName Name of the Confidential Ledger
|
69
|
+
* @param options The options parameters.
|
70
|
+
*/
|
71
|
+
beginDeleteAndWait(
|
72
|
+
resourceGroupName: string,
|
73
|
+
ledgerName: string,
|
74
|
+
options?: LedgerDeleteOptionalParams
|
75
|
+
): Promise<void>;
|
76
|
+
/**
|
77
|
+
* Creates a Confidential Ledger with the specified ledger parameters.
|
78
|
+
* @param resourceGroupName The name of the resource group.
|
79
|
+
* @param ledgerName Name of the Confidential Ledger
|
80
|
+
* @param confidentialLedger Confidential Ledger Create Request Body
|
81
|
+
* @param options The options parameters.
|
82
|
+
*/
|
83
|
+
beginCreate(
|
84
|
+
resourceGroupName: string,
|
85
|
+
ledgerName: string,
|
86
|
+
confidentialLedger: ConfidentialLedger,
|
87
|
+
options?: LedgerCreateOptionalParams
|
88
|
+
): Promise<
|
89
|
+
PollerLike<PollOperationState<LedgerCreateResponse>, LedgerCreateResponse>
|
90
|
+
>;
|
91
|
+
/**
|
92
|
+
* Creates a Confidential Ledger with the specified ledger parameters.
|
93
|
+
* @param resourceGroupName The name of the resource group.
|
94
|
+
* @param ledgerName Name of the Confidential Ledger
|
95
|
+
* @param confidentialLedger Confidential Ledger Create Request Body
|
96
|
+
* @param options The options parameters.
|
97
|
+
*/
|
98
|
+
beginCreateAndWait(
|
99
|
+
resourceGroupName: string,
|
100
|
+
ledgerName: string,
|
101
|
+
confidentialLedger: ConfidentialLedger,
|
102
|
+
options?: LedgerCreateOptionalParams
|
103
|
+
): Promise<LedgerCreateResponse>;
|
104
|
+
/**
|
105
|
+
* Updates properties of Confidential Ledger
|
106
|
+
* @param resourceGroupName The name of the resource group.
|
107
|
+
* @param ledgerName Name of the Confidential Ledger
|
108
|
+
* @param confidentialLedger Confidential Ledger request body for Updating Ledger
|
109
|
+
* @param options The options parameters.
|
110
|
+
*/
|
111
|
+
beginUpdate(
|
112
|
+
resourceGroupName: string,
|
113
|
+
ledgerName: string,
|
114
|
+
confidentialLedger: ConfidentialLedger,
|
115
|
+
options?: LedgerUpdateOptionalParams
|
116
|
+
): Promise<
|
117
|
+
PollerLike<PollOperationState<LedgerUpdateResponse>, LedgerUpdateResponse>
|
118
|
+
>;
|
119
|
+
/**
|
120
|
+
* Updates properties of Confidential Ledger
|
121
|
+
* @param resourceGroupName The name of the resource group.
|
122
|
+
* @param ledgerName Name of the Confidential Ledger
|
123
|
+
* @param confidentialLedger Confidential Ledger request body for Updating Ledger
|
124
|
+
* @param options The options parameters.
|
125
|
+
*/
|
126
|
+
beginUpdateAndWait(
|
127
|
+
resourceGroupName: string,
|
128
|
+
ledgerName: string,
|
129
|
+
confidentialLedger: ConfidentialLedger,
|
130
|
+
options?: LedgerUpdateOptionalParams
|
131
|
+
): Promise<LedgerUpdateResponse>;
|
132
|
+
}
|
@@ -0,0 +1,25 @@
|
|
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 {
|
11
|
+
ResourceProviderOperationDefinition,
|
12
|
+
OperationsListOptionalParams
|
13
|
+
} from "../models";
|
14
|
+
|
15
|
+
/// <reference lib="esnext.asynciterable" />
|
16
|
+
/** Interface representing a Operations. */
|
17
|
+
export interface Operations {
|
18
|
+
/**
|
19
|
+
* Retrieves a list of available API operations
|
20
|
+
* @param options The options parameters.
|
21
|
+
*/
|
22
|
+
list(
|
23
|
+
options?: OperationsListOptionalParams
|
24
|
+
): PagedAsyncIterableIterator<ResourceProviderOperationDefinition>;
|
25
|
+
}
|
package/tsconfig.json
ADDED
@@ -0,0 +1,33 @@
|
|
1
|
+
{
|
2
|
+
"compilerOptions": {
|
3
|
+
"module": "es6",
|
4
|
+
"moduleResolution": "node",
|
5
|
+
"strict": true,
|
6
|
+
"target": "es6",
|
7
|
+
"sourceMap": true,
|
8
|
+
"declarationMap": true,
|
9
|
+
"esModuleInterop": true,
|
10
|
+
"allowSyntheticDefaultImports": true,
|
11
|
+
"forceConsistentCasingInFileNames": true,
|
12
|
+
"lib": [
|
13
|
+
"es6",
|
14
|
+
"dom"
|
15
|
+
],
|
16
|
+
"declaration": true,
|
17
|
+
"outDir": "./dist-esm",
|
18
|
+
"importHelpers": true,
|
19
|
+
"paths": {
|
20
|
+
"@azure/arm-confidentialledger": [
|
21
|
+
"./src/index"
|
22
|
+
]
|
23
|
+
}
|
24
|
+
},
|
25
|
+
"include": [
|
26
|
+
"./src/**/*.ts",
|
27
|
+
"./test/**/*.ts",
|
28
|
+
"samples-dev/**/*.ts"
|
29
|
+
],
|
30
|
+
"exclude": [
|
31
|
+
"node_modules"
|
32
|
+
]
|
33
|
+
}
|