/**
 * Transaction management for GQLDB Node.js driver.
 */
/** Represents an active database transaction */
export interface Transaction {
    id: number;
    sessionId: number;
    graphName: string;
    readOnly: boolean;
    createdAt: number;
    timeout: number;
    committed: boolean;
    rolledBack: boolean;
    /**
     * Stable per-client logical session id surfaced under the
     * transaction-branch model. Distinct from `sessionId: number` (the
     * legacy uint64 from Login). Always populated by the driver. See
     * TRANSACTIONS_DRIVER_GUIDE.md §2.0–2.1.
     */
    clientSessionId: string;
}
/** Manages transactions for the client */
export declare class TransactionManager {
    private transactions;
    /** Create a new transaction */
    begin(txId: number, sessionId: number, graphName: string, readOnly: boolean, timeout: number, clientSessionId?: string): Transaction;
    /** Mark a transaction as committed */
    commit(txId: number): void;
    /** Mark a transaction as rolled back */
    rollback(txId: number): void;
    /** Get a transaction by ID */
    get(txId: number): Transaction | undefined;
    /** Get all active transactions */
    getActive(): Transaction[];
    /** Get all active transactions for a session */
    getActiveForSession(sessionId: number): Transaction[];
    /** Check if there are any active transactions */
    hasActive(): boolean;
    /** Get the number of active transactions */
    count(): number;
    /** Clear all transactions */
    clearAll(): void;
    /** Check if a transaction is active */
    isActive(txId: number): boolean;
    /** Check if a transaction has expired */
    isExpired(txId: number): boolean;
    /** Get transaction age in milliseconds */
    age(txId: number): number;
}
