import { Result } from '@kizahasi/result'; import { r, i, d, ComposeAndTransformError, PositiveInt, Operation, ApplyError } from '@kizahasi/ot-core'; import { NonEmptyString } from '../nonEmptyString'; import * as TextTwoWayOperation from './twoWayOperation'; export type UpOperation = Operation; export type UpOperationUnit = { t: typeof r; r: number; } | { t: typeof i; i: string; } | { t: typeof d; d: number; }; export declare const apply: ({ prevState, upOperation, }: { prevState: string; upOperation: UpOperation; }) => Result>; export declare const applyAndRestore: ({ prevState, upOperation, }: { prevState: string; upOperation: UpOperation; }) => Result<{ nextState: string; restored: TextTwoWayOperation.TwoWayOperation; }, ApplyError>; export declare const compose: ({ first, second, }: { first: UpOperation; second: UpOperation; }) => Result>; export declare const transform: ({ first, second, }: { first: UpOperation; second: UpOperation; }) => Result<{ firstPrime: UpOperation; secondPrime: UpOperation; }, ComposeAndTransformError>; export declare const invert: (source: UpOperation) => Operation; export declare const toUnit: (source: UpOperation) => UpOperationUnit[]; export declare const ofUnit: (source: ReadonlyArray) => UpOperation; //# sourceMappingURL=upOperation.d.ts.map