KeyStorageImpl
@icure/medical-device-sdk / KeyStorageImpl
Class: KeyStorageImpl
Implements
Table of contents
Constructors
Properties
Methods
Constructors
constructor
• new KeyStorageImpl(storage
)
Parameters
Name | Type |
---|---|
storage | StorageFacade <string > |
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:5
Properties
_storage
• Private
Readonly
_storage: any
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:4
Methods
deleteKeypair
▸ deleteKeypair(key
): Promise
<void
>
Delete the keyPair associated to the provided key
Parameters
Name | Type | Description |
---|---|---|
key | string | Key of the value to delete |
Returns
Promise
<void
>
Implementation of
KeyStorageFacade.deleteKeypair
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:6
getKeypair
▸ getKeypair(key
): Promise
<undefined
| { privateKey
: JsonWebKey
; publicKey
: JsonWebKey
}>
Get the keyPair associated to the provided key
Parameters
Name | Type | Description |
---|---|---|
key | string | Key of the value to retrieve |
Returns
Promise
<undefined
| { privateKey
: JsonWebKey
; publicKey
: JsonWebKey
}>
The keyPair associated to the provided key or undefined if not found.
Implementation of
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:7
getPrivateKey
▸ getPrivateKey(key
): Promise
<undefined
| JsonWebKey
>
Returns the privateKey of the provided key from the storage
Parameters
Name | Type | Description |
---|---|---|
key | string | Key of the value to retrieve |
Returns
Promise
<undefined
| JsonWebKey
>
The privateKey associated to the provided key or undefined if not found.
Implementation of
KeyStorageFacade.getPrivateKey
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:11
getPublicKey
▸ getPublicKey(key
): Promise
<undefined
| JsonWebKey
>
Returns the publicKey of the provided key from the storage
Parameters
Name | Type | Description |
---|---|---|
key | string | Key of the value to retrieve |
Returns
Promise
<undefined
| JsonWebKey
>
The publicKey associated to the provided key or undefined if not found.
Implementation of
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:12
storeKeyPair
▸ storeKeyPair(key
, keyPair
): Promise
<void
>
Stores the given keyPair under the given key in the storage.
Parameters
Name | Type | Description |
---|---|---|
key | string | The id of the entry in storage |
keyPair | Object | should be JWK |
keyPair.privateKey | JsonWebKey | - |
keyPair.publicKey | JsonWebKey | - |
Returns
Promise
<void
>
Implementation of
Defined in
node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:13