Skip to main content

KeyStorageImpl

@icure/medical-device-sdk / KeyStorageImpl

Class: KeyStorageImpl

Implements

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new KeyStorageImpl(storage)

Parameters

NameType
storageStorageFacade<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

NameTypeDescription
keystringKey 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

NameTypeDescription
keystringKey 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

KeyStorageFacade.getKeypair

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

NameTypeDescription
keystringKey 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

NameTypeDescription
keystringKey of the value to retrieve

Returns

Promise<undefined | JsonWebKey>

The publicKey associated to the provided key or undefined if not found.

Implementation of

KeyStorageFacade.getPublicKey

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

NameTypeDescription
keystringThe id of the entry in storage
keyPairObjectshould be JWK
keyPair.privateKeyJsonWebKey-
keyPair.publicKeyJsonWebKey-

Returns

Promise<void>

Implementation of

KeyStorageFacade.storeKeyPair

Defined in

node_modules/@icure/api/icc-x-api/storage/KeyStorageImpl.d.ts:13