Options
All
  • Public
  • Public/Protected
  • All
Menu

Class RightWrapper<A, B>

Type parameters

  • A

  • B

Hierarchy

Implements

Index

Constructors

constructor

Properties

a

a: A

b

b: B

Accessors

@@__TSFP_RECORD__@@

  • get @@__TSFP_RECORD__@@(): boolean

isLeft

  • get isLeft(): boolean

isRight

  • get isRight(): boolean

left

right

swap

Methods

equals

  • equals(that: any): boolean

fold

  • fold<X, Y>(fa: function, fb: function): X | Y
  • Applies fa if this is a Left or fb if this is a Right.

    Type parameters

    • X

    • Y

    Parameters

    • fa: function

      the function to apply if this is a Left

        • (a: A): X
        • Parameters

          • a: A

          Returns X

    • fb: function

      the function to apply if this is a Right

        • (b: B): Y
        • Parameters

          • b: B

          Returns Y

    Returns X | Y

    the results of applying the function

getIsLeft

  • getIsLeft(): boolean

getIsRight

  • getIsRight(): boolean

toString

  • toString(): string

Static Left

  • Left<X, Y>(value: X): Either<X, Y>

Static Right

  • Right<X, Y>(value: Y): Either<X, Y>

Static isEither

  • isEither(value: any): boolean

Static isLeft

  • isLeft(value: any): any

Static isRight

  • isRight(value: any): any

Generated using TypeDoc