export declare class Result { isSuccess: boolean; isFailure: boolean; error: T | string; private _value; constructor(isSuccess: boolean, error?: T | string, value?: T); getValue(): T; errorValue(): T; static ok(value?: U): Result; static fail(error: string): Result; static combine(results: Result[]): Result; } export declare type Either = Left | Right; export declare class Left { readonly value: L; constructor(value: L); isLeft(): this is Left; isRight(): this is Right; } export declare class Right { readonly value: A; constructor(value: A); isLeft(): this is Left; isRight(): this is Right; } export declare const left: (l: L) => Either; export declare const right: (a: A) => Either;