Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • Create

Index

Constructors

Methods

  • combine<T>(members: T): Box<CombineSuccessType<T>, ValueOf<{ [ P in string | number | symbol]: FailureType<T[P]> }>>
  • combine<T>(members: T): Break<CombineSuccessType<T>, ValueOf<{ [ P in string | number | symbol]: FailureType<T[P]> }>>
  • combine<SA, FA>(results: [Box<SA, FA>]): Box<[SA], FA>
  • combine<SA, FA>(results: [Break<SA, FA>]): Break<[SA], FA>
  • combine<SA, FA, SB, FB>(results: [Box<SA, FB>, Box<SB, FB>]): Box<[SA, SB], FA | FB>
  • combine<SA, FA, SB, FB>(results: [Break<SA, FB>, Break<SB, FB>]): Break<[SA, SB], FA | FB>
  • combine<SA, FA, SB, FB, SC, FC>(results: [Box<SA, FA>, Box<SB, FB>, Box<SC, FC>]): Box<[SA, SB, SC], FA | FB | FC>
  • combine<SA, FA, SB, FB, SC, FC>(results: [Break<SA, FA>, Break<SB, FB>, Break<SC, FC>]): Break<[SA, SB, SC], FA | FB | FC>
  • combine<SA, FA, SB, FB, SC, FC, SD, FD>(results: [Box<SA, FA>, Box<SB, FB>, Box<SC, FC>, Box<SD, FD>]): Box<[SA, SA, SC, SD], FA | FB | FC | FD>
  • combine<SA, FA, SB, FB, SC, FC, SD, FD>(results: [Break<SA, FA>, Break<SB, FB>, Break<SC, FC>, Break<SD, FD>]): Break<[SA, SA, SC, SD], FA | FB | FC | FD>
  • combine<SA, FA, SB, FB, SC, FC, SD, FD, SE, FE>(results: [Box<SA, FA>, Box<SB, FB>, Box<SC, FC>, Box<SD, FD>, Box<SE, FE>]): Box<[SA, SA, SC, SD, SE], FA | FB | FC | FD | FE>
  • combine<SA, FA, SB, FB, SC, FC, SD, FD, SE, FE>(results: [Break<SA, FA>, Break<SB, FB>, Break<SC, FC>, Break<SD, FD>, Break<SE, FE>]): Break<[SA, SA, SC, SD, SE], FA | FB | FC | FD | FE>
  • combine<SA, FA, SB, FB, SC, FC, SD, FD, SE, FE, SF, FF>(results: [Box<SA, FA>, Box<SB, FB>, Box<SC, FC>, Box<SD, FD>, Box<SE, FE>, Box<SF, FF>]): Box<[SA, SA, SC, SD, SE, SF], FA | FB | FC | FD | FE | FF>
  • combine<SA, FA, SB, FB, SC, FC, SD, FD, SE, FE, SF, FF>(results: [Break<SA, FA>, Break<SB, FB>, Break<SC, FC>, Break<SD, FD>, Break<SE, FE>, Break<SF, FF>]): Break<[SA, SA, SC, SD, SE, SF], FA | FB | FC | FD | FE | FF>
  • combine<S, F>(observables: Box<S, F>[]): Box<S[], F>
  • combine<S, F>(observables: Break<S, F>[]): Break<S[], F>
  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • T extends Dictionary<Box<any, any>>

    Parameters

    • members: T

    Returns Box<CombineSuccessType<T>, ValueOf<{ [ P in string | number | symbol]: FailureType<T[P]> }>>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • T extends Dictionary<Break<any, any>>

    Parameters

    • members: T

    Returns Break<CombineSuccessType<T>, ValueOf<{ [ P in string | number | symbol]: FailureType<T[P]> }>>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    Parameters

    • results: [Box<SA, FA>]

    Returns Box<[SA], FA>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    Parameters

    Returns Break<[SA], FA>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    Parameters

    • results: [Box<SA, FB>, Box<SB, FB>]

    Returns Box<[SA, SB], FA | FB>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    Parameters

    Returns Break<[SA, SB], FA | FB>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    Parameters

    • results: [Box<SA, FA>, Box<SB, FB>, Box<SC, FC>]

    Returns Box<[SA, SB, SC], FA | FB | FC>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    Parameters

    Returns Break<[SA, SB, SC], FA | FB | FC>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    • SD

    • FD

    Parameters

    • results: [Box<SA, FA>, Box<SB, FB>, Box<SC, FC>, Box<SD, FD>]

    Returns Box<[SA, SA, SC, SD], FA | FB | FC | FD>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    • SD

    • FD

    Parameters

    Returns Break<[SA, SA, SC, SD], FA | FB | FC | FD>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    • SD

    • FD

    • SE

    • FE

    Parameters

    Returns Box<[SA, SA, SC, SD, SE], FA | FB | FC | FD | FE>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    • SD

    • FD

    • SE

    • FE

    Parameters

    Returns Break<[SA, SA, SC, SD, SE], FA | FB | FC | FD | FE>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    • SD

    • FD

    • SE

    • FE

    • SF

    • FF

    Parameters

    Returns Box<[SA, SA, SC, SD, SE, SF], FA | FB | FC | FD | FE | FF>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • SA

    • FA

    • SB

    • FB

    • SC

    • FC

    • SD

    • FD

    • SE

    • FE

    • SF

    • FF

    Parameters

    Returns Break<[SA, SA, SC, SD, SE, SF], FA | FB | FC | FD | FE | FF>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • S

    • F

    Parameters

    • observables: Box<S, F>[]

    Returns Box<S[], F>

  • Combines multiple results. Takes either a record or an array of result. Returns a result that will be failed if any of the input results fail, otherwise return null if any of the inputs are null, or succeed with data of a record or array of the result's data fields.

    Type Parameters

    • S

    • F

    Parameters

    • observables: Break<S, F>[]

    Returns Break<S[], F>

  • execute<S>(fn: NullaryFn<S>): Box<S, Error>
  • Creates a result that will be successful and contain the return value of fn as data, or otherwise be failed if fn throws.

    Type Parameters

    • S

    Parameters

    • fn: NullaryFn<S>

    Returns Box<S, Error>

  • Creates a failed result with data.

    Type Parameters

    • F

    Parameters

    • data: F

    Returns Failure<F>

  • observable<S>(Constructor: LikeConstructor, observable: Like<S>, completeOnFail?: boolean): Like<Box<S, Error>>
  • Returns an Observable of result, that will be successful as long as the original observable doesn't error, and failed otherwise.

    Type Parameters

    • S

    Parameters

    • Constructor: LikeConstructor

      an ES Observable constructor

    • observable: Like<S>

      an ES Observable

    • Optional completeOnFail: boolean

      whether the resulting observable should complete after a failed result

    Returns Like<Box<S, Error>>

  • promise<S>(promise: MaybePromiseLike<S> | NullaryFn<MaybePromiseLike<S>>): Promise<Box<S, Error>>
  • Returns a Promise of a result, that will be successful if promise resolves, and failed otherwise.

    Type Parameters

    • S

    Parameters

    • promise: MaybePromiseLike<S> | NullaryFn<MaybePromiseLike<S>>

      a promise or a promise returning function

    Returns Promise<Box<S, Error>>

  • Creates a successful result with data.

    Type Parameters

    • S

    Parameters

    • data: S

    Returns Success<S>

Generated using TypeDoc