import { type LiteralInput, type RecalcMetrics } from '@bilig/protocol';
import type { EngineExistingNumericCellMutationResult } from '../../cell-mutations-at.js';
import type { SheetRecord } from '../../workbook-store.js';
import type { CreateEngineOperationServiceArgs } from './operation-service-types.js';
export interface OperationTrustedFormulaLeafExistingNumericMutationRequest {
    readonly existingIndex: number;
    readonly formulaCellIndex: number;
    readonly sheet: SheetRecord;
    readonly col: number;
    readonly value: number;
    readonly oldNumber: number;
    readonly hasTrackedEventListeners: boolean;
}
export interface OperationFormulaLeafExistingLiteralMutationRequest {
    readonly existingIndex: number;
    readonly formulaCellIndex: number;
    readonly value: LiteralInput;
    readonly hasTrackedEventListeners: boolean;
}
export interface OperationFormulaLeafExistingNumericFastPathArgs {
    readonly state: Pick<CreateEngineOperationServiceArgs['state'], 'workbook' | 'strings' | 'wasm' | 'formulas' | 'counters' | 'events' | 'setLastMetrics'>;
    readonly getSingleEntityDependent: (entityId: number) => number;
    readonly writeTrustedExistingNumericLiteralToCell: (existingIndex: number, sheet: SheetRecord, col: number, value: number) => void;
    readonly evaluateFormulaCell: (formulaCellIndex: number) => readonly number[];
    readonly deferSingleCellKernelSync: (cellIndex: number) => void;
    readonly makeSingleLiteralSkipMetrics: () => RecalcMetrics;
}
export interface OperationFormulaLeafExistingLiteralFastPathArgs {
    readonly state: OperationFormulaLeafExistingNumericFastPathArgs['state'];
    readonly getSingleEntityDependent: (entityId: number) => number;
    readonly writeFastPathLiteralToExistingCell: (existingIndex: number, value: LiteralInput) => void;
    readonly evaluateFormulaCell: (formulaCellIndex: number) => readonly number[];
    readonly deferSingleCellKernelSync: (cellIndex: number) => void;
    readonly makeSingleLiteralSkipMetrics: () => RecalcMetrics;
}
export declare function tryApplyTrustedFormulaLeafExistingNumericMutation(args: OperationFormulaLeafExistingNumericFastPathArgs, request: OperationTrustedFormulaLeafExistingNumericMutationRequest): EngineExistingNumericCellMutationResult | null;
export declare function tryApplyFormulaLeafExistingLiteralMutation(args: OperationFormulaLeafExistingLiteralFastPathArgs, request: OperationFormulaLeafExistingLiteralMutationRequest): EngineExistingNumericCellMutationResult | null;
