import { chaCha20Poly1305 } from "@hazae41/chacha20poly1305";
import { Cursor } from "@hazae41/cursor";
export type Cipher = typeof Cipher.ArcFourVariant | typeof Cipher.Salsa20 | typeof Cipher.ChaCha20;
export declare namespace Cipher {
    class ArcFourVariant {
        constructor();
    }
    namespace ArcFourVariant {
        const type = 1;
        function cloneOrThrow(): typeof ArcFourVariant;
        function sizeOrThrow(): number;
        function writeOrThrow(cursor: Cursor<ArrayBuffer>): void;
        function initOrThrow(seed: Uint8Array): Promise<never>;
    }
    class Salsa20 {
        readonly key: Uint8Array;
        readonly nonce: Uint8Array;
        constructor(key: Uint8Array, nonce: Uint8Array);
    }
    namespace Salsa20 {
        const type = 2;
        function cloneOrThrow(): typeof Salsa20;
        function sizeOrThrow(): number;
        function writeOrThrow(cursor: Cursor<ArrayBuffer>): void;
        function initOrThrow(seed: Uint8Array): Promise<never>;
    }
    class ChaCha20 {
        readonly cipher: chaCha20Poly1305.Abstract.ChaCha20Cipher;
        constructor(cipher: chaCha20Poly1305.Abstract.ChaCha20Cipher);
        [Symbol.dispose](): void;
        applyOrThrow(data: Uint8Array): chaCha20Poly1305.Abstract.Memory;
    }
    namespace ChaCha20 {
        const type = 3;
        function cloneOrThrow(): typeof ChaCha20;
        function sizeOrThrow(): number;
        function writeOrThrow(cursor: Cursor<ArrayBuffer>): void;
        function initOrThrow(seed: Uint8Array<ArrayBuffer>): Promise<ChaCha20>;
    }
}
export declare namespace Cipher {
    function readOrThrow(cursor: Cursor<ArrayBuffer>): Cipher;
}
