import { default as BiFunctor } from '../../interface/Bifunctor';
import { default as Monad } from '../../interface/Monad';
import { default as PatternMatch } from '../../interface/Patternmatch';
import { default as Setoid } from '../../interface/Setoid';
import { default as Maybe } from '../Maybe';
declare abstract class Either implements Setoid, BiFunctor, Monad, PatternMatch {
protected _value: A | B;
static of(v: D): Either;
static Right(v: D): Either;
static Left(v: C): Either;
static fromNullable(v: any): Either;
static withDefault(def: B | null | undefined, v: B): Either;
static swap(e: Either): Either;
static try(f: Function): (...args: Array) => Either;
static bimap(e: Either, fl: (a: G) => C, fr: (b: K) => D): Either;
static isLeft(v: Either): boolean;
static isRight(v: Either): boolean;
of(v: B): Either;
ap(j: Either): Either;
getValue(): A | B;
abstract equals(n: Setoid): boolean;
abstract map(f: (a: B) => C): Either;
abstract bimap(fl: (a: A) => C, fr: (a: B) => D): Either;
abstract chain(f: (a: B) => Either): Either;
abstract caseOf(o: {
Left: (a: A) => T;
Right: (a: B) => T;
}): T;
abstract swap(): Either;
abstract isLeft(): boolean;
abstract isRight(): boolean;
}
export default Either;
export declare const maybeToEither: (m: Maybe) => any;