diff --git a/src/blst/index.ts b/src/blst/index.ts index f4d8b1b..f2093cf 100644 --- a/src/blst/index.ts +++ b/src/blst/index.ts @@ -1,4 +1,3 @@ -import {Keypair} from "./keypair"; import {PrivateKey} from "./privateKey"; import {PublicKey} from "./publicKey"; import {Signature} from "./signature"; @@ -6,7 +5,7 @@ import {IBls} from "../interface"; export * from "../constants"; import {functionalInterfaceFactory} from "../functional"; -export {Keypair, PrivateKey, PublicKey, Signature}; +export {PrivateKey, PublicKey, Signature}; export async function initBLS(): Promise { // Native bindings require no init() call @@ -16,7 +15,6 @@ export function destroy(): void { } export const bls: IBls = { - // Keypair, PrivateKey, PublicKey, Signature, diff --git a/src/blst/keypair.ts b/src/blst/keypair.ts deleted file mode 100644 index db3928e..0000000 --- a/src/blst/keypair.ts +++ /dev/null @@ -1,30 +0,0 @@ -import {PublicKey} from "./publicKey"; -import {PrivateKey} from "./privateKey"; -import {IKeypair} from "../interface"; - -export class Keypair implements IKeypair { - private readonly _publicKey: PublicKey; - - private readonly _privateKey: PrivateKey; - - public constructor(privateKey: PrivateKey, publicKey?: PublicKey) { - this._privateKey = privateKey; - if (!publicKey) { - this._publicKey = privateKey.toPublicKey(); - } else { - this._publicKey = publicKey; - } - } - - public get publicKey(): PublicKey { - return this._publicKey; - } - - public get privateKey(): PrivateKey { - return this._privateKey; - } - - public static generate(): Keypair { - return new Keypair(PrivateKey.fromKeygen()); - } -} diff --git a/src/herumi/index.ts b/src/herumi/index.ts index a8afed8..67b5688 100644 --- a/src/herumi/index.ts +++ b/src/herumi/index.ts @@ -1,4 +1,3 @@ -import {Keypair} from "./keypair"; import {PrivateKey} from "./privateKey"; import {PublicKey} from "./publicKey"; import {Signature} from "./signature"; @@ -6,10 +5,9 @@ import {initBLS, destroy} from "./context"; import {IBls} from "../interface"; import {functionalInterfaceFactory} from "../functional"; -export {Keypair, PrivateKey, PublicKey, Signature, initBLS, destroy}; +export {PrivateKey, PublicKey, Signature, initBLS, destroy}; const bls: IBls = { - // Keypair, PrivateKey, PublicKey, Signature, diff --git a/src/herumi/keypair.ts b/src/herumi/keypair.ts deleted file mode 100644 index db3928e..0000000 --- a/src/herumi/keypair.ts +++ /dev/null @@ -1,30 +0,0 @@ -import {PublicKey} from "./publicKey"; -import {PrivateKey} from "./privateKey"; -import {IKeypair} from "../interface"; - -export class Keypair implements IKeypair { - private readonly _publicKey: PublicKey; - - private readonly _privateKey: PrivateKey; - - public constructor(privateKey: PrivateKey, publicKey?: PublicKey) { - this._privateKey = privateKey; - if (!publicKey) { - this._publicKey = privateKey.toPublicKey(); - } else { - this._publicKey = publicKey; - } - } - - public get publicKey(): PublicKey { - return this._publicKey; - } - - public get privateKey(): PrivateKey { - return this._privateKey; - } - - public static generate(): Keypair { - return new Keypair(PrivateKey.fromKeygen()); - } -}