/** * A `Result` type indicating success, in which case the object has a `value` key of type `T`, * or failure, in which case the object has an `error` key of type `E`. * * @typeParam T the type of `value` if the result indicates success * @typeParam E the type of `error` if the result indicates failure */ export declare type Result = { ok: true; value: T; } | { ok: false; error: E; }; /** * @param value - The value of a successful operation * @returns the Result object representing a successful operation */ export declare function Ok(value: T): Result; /** * @param error - The error encountered when an operation failed * @returns the Result object representing failed operation */ export declare function Err(error: E): Result;