import { IPrivateKey , ICrypto , IPrivateKeyExporter , Data } from './types' ; export class VirgilPrivateKeyExporter implements IPrivateKeyExporter { readonly crypto : ICrypto ; constructor ( crypto ) { if ( crypto == null ) { throw new Error ( '`crypto` is required' ) ; } this . crypto = crypto ; } exportPrivateKey ( key ) { return this . crypto . exportPrivateKey ( key ) ; } importPrivateKey ( keyData ) { return this . crypto . importPrivateKey ( keyData ) ; } }