import { CLType, CLValue, CLValueBytesParsers, CLErrorCodes, ResultAndRemainder, ToBytesResult } from './index'; import { CLTypeTag } from './constants'; import { SignatureAlgorithm } from '../Keys'; export declare enum CLPublicKeyTag { ED25519 = 1, SECP256K1 = 2 } export declare class CLPublicKeyType extends CLType { linksTo: string; tag: CLTypeTag; } export declare class CLPublicKeyBytesParser extends CLValueBytesParsers { toBytes(value: CLPublicKey): ToBytesResult; fromBytesWithRemainder(rawBytes: Uint8Array): ResultAndRemainder; } export declare class CLPublicKey extends CLValue { data: Uint8Array; tag: CLPublicKeyTag; constructor(rawPublicKey: Uint8Array, tag: CLPublicKeyTag | SignatureAlgorithm); clType(): CLType; isEd25519(): boolean; isSecp256K1(): boolean; toHex(checksummed?: boolean): string; toAccountHash(): Uint8Array; toAccountHashStr(): string; toAccountRawHashStr(): string; value(): Uint8Array; static fromEd25519(publicKey: Uint8Array): CLPublicKey; static fromSecp256K1(publicKey: Uint8Array): CLPublicKey; /** * Tries to decode PublicKey from its hex-representation. * The hex format should be as produced by CLPublicKey.toHex * @param publicKeyHex public key hex string contains key tag * @param checksummed throws an Error if true and given string is not checksummed */ static fromHex(publicKeyHex: string, checksummed?: boolean): CLPublicKey; getTag(): CLPublicKeyTag; getSignatureAlgorithm(): SignatureAlgorithm; }