import type { PaneResult } from '../types'; import type { CmuxCloseIntent } from './close-policy'; export type CmuxSpawnState = 'known' | 'spawning' | 'attached' | 'failed'; export type CmuxLifecycleState = 'active' | 'deleted' | 'orphaned'; export interface CmuxDeferredSpawn { deadline: number; generation: number; timer?: { cancel(): void; }; } export interface CmuxSessionRecord { session: string; owner: string; parent: string; title: string; directory: string; paneId?: string; spawnState: CmuxSpawnState; lifecycle: CmuxLifecycleState; attachedAt?: number; lastActivityAt: number; activityVersion: number; idleConsecutive: number; statusMissingSince?: number; deferredSpawn?: CmuxDeferredSpawn; closeIntent?: CmuxCloseIntent; closeTimer?: { cancel(): void; }; spawnPromise?: Promise; } export declare class CmuxSessionStore { claimCreated(record: CmuxSessionRecord): boolean; get(session: string): CmuxSessionRecord | undefined; ownedBy(owner: string): CmuxSessionRecord[]; claimOrphans(owner: string, directory: string): CmuxSessionRecord[]; markAttached(session: string, paneId: string, now: number): void; markActivity(session: string, now: number): void; markDeleted(session: string): void; markOrphaned(session: string): void; removeAfterConfirmedClose(session: string): boolean; removeWithoutPane(session: string): boolean; resetForTests(): void; }