/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
import type { GroupKeyManagement } from "#clusters/group-key-management";
import { BasicSet, Bytes, Crypto, Timestamp } from "#general";
export declare const GROUP_KEY_INFO: AllowSharedBufferSource;
export declare class KeySets<T extends OperationalKeySet> extends BasicSet<T> {
    #private;
    get sessions(): Map<number, {
        keySetId: number;
        key: Bytes;
    }[]>;
    add(item: T): void;
    delete<F extends keyof T>(itemOrField: T | F, value?: T[F]): boolean;
    forId(groupKeySetId: number): OperationalKeySet | undefined;
    /**
     * Return an operative list of operational keys, start time and their session IDs for a specified
     * group key set id. This is mainly used for receiving messages.
     */
    allKeysForId(keySetId: number): {
        key: Bytes;
        sessionId?: number;
        startTime: Timestamp;
    }[];
    /**
     * Returns the current operational group key for a given group KeySet Id and returns the keys, start time and
     * their session IDs. This is mainly used for sending messages.
     */
    currentKeyForId(keySetId: number): {
        key: Bytes;
        sessionId?: number;
        startTime: Timestamp;
    };
    /**
     * Returns the group key set for a given group key set id in the official data format from the Group key Management
     * cluster.
     */
    asGroupKeySet(groupKeySetId: number): {
        groupKeySetId: number;
        epochKey0: AllowSharedBufferSource | null;
        epochStartTime0: number | bigint | null;
        epochKey1: AllowSharedBufferSource | null;
        epochStartTime1: number | bigint | null;
        epochKey2: AllowSharedBufferSource | null;
        epochStartTime2: number | bigint | null;
        groupKeySecurityPolicy: GroupKeyManagement.GroupKeySecurityPolicy;
        groupKeyMulticastPolicy: GroupKeyManagement.GroupKeyMulticastPolicy | undefined;
    } | undefined;
    /** Calculates a group session id based on the operational group key. */
    sessionIdFromKey(crypto: Crypto, operationalGroupKey: Bytes): Promise<number>;
}
export type GroupKeySet = GroupKeyManagement.GroupKeySet;
/** Enhanced structure of GroupKeySet to include operational data for easier operational processing. */
export type OperationalKeySet = GroupKeySet & {
    operationalEpochKey0: Bytes;
    groupSessionId0: number | null;
    operationalEpochKey1: Bytes | null;
    groupSessionId1: number | null;
    operationalEpochKey2: Bytes | null;
    groupSessionId2: number | null;
};
//# sourceMappingURL=KeySets.d.ts.map