Link Search Menu Expand Document

ObservableThese overview

Added in v0.6.12


Table of contents


Applicative

of

Signature

export declare const of: <E, A>(a: A) => ObservableThese<E, A>

Added in v0.6.12

Bifunctor

bimap

Signature

export declare const bimap: <E, G, A, B>(
  f: (e: E) => G,
  g: (a: A) => B
) => (fa: ObservableThese<E, A>) => ObservableThese<G, B>

Added in v0.6.12

mapLeft

Signature

export declare const mapLeft: <E, G>(f: (e: E) => G) => <A>(fa: ObservableThese<E, A>) => ObservableThese<G, A>

Added in v0.6.12

Functor

map

map can be used to turn functions (a: A) => B into functions (fa: F<A>) => F<B> whose argument and return types use the type constructor F to represent some computational context.

Signature

export declare const map: <A, B>(f: (a: A) => B) => <E>(fa: ObservableThese<E, A>) => ObservableThese<E, B>

Added in v0.6.12

combinators

swap

Signature

export declare const swap: <E, A>(ma: ObservableThese<E, A>) => ObservableThese<A, E>

Added in v0.6.12

constructors

both

Signature

export declare const both: <E = never, A = never>(e: E, a: A) => ObservableThese<E, A>

Added in v0.6.12

fromIO

Signature

export declare const fromIO: <E, A>(fa: IO<A>) => ObservableThese<E, A>

Added in v0.6.12

fromIOEither

Signature

export declare const fromIOEither: <E, A>(fa: IOEither<E, A>) => ObservableThese<E, A>

Added in v0.6.12

fromTask

Signature

export declare const fromTask: <E, A>(fa: Task<A>) => ObservableThese<E, A>

Added in v0.6.12

fromTaskThese

Signature

export declare const fromTaskThese: <E, A>(t: TT.TaskThese<E, A>) => ObservableThese<E, A>

Added in v0.6.12

left

Signature

export declare const left: <E = never, A = never>(e: E) => ObservableThese<E, A>

Added in v0.6.12

leftIO

Signature

export declare const leftIO: <E = never, A = never>(me: IO<E>) => ObservableThese<E, A>

Added in v0.6.12

leftObservable

Signature

export declare const leftObservable: <E = never, A = never>(ma: Observable<E>) => ObservableThese<E, A>

Added in v0.6.12

Signature

export declare const right: <E = never, A = never>(a: A) => ObservableThese<E, A>

Added in v0.6.12

rightIO

Signature

export declare const rightIO: <E = never, A = never>(ma: IO<A>) => ObservableThese<E, A>

Added in v0.6.12

rightObservable

Signature

export declare const rightObservable: <E = never, A = never>(ma: Observable<A>) => ObservableThese<E, A>

Added in v0.6.12

destructors

fold

Signature

export declare const fold: <E, A, B>(
  onLeft: (e: E) => Observable<B>,
  onRight: (a: A) => Observable<B>,
  onBoth: (e: E, a: A) => Observable<B>
) => (ma: ObservableThese<E, A>) => Observable<B>

Added in v0.6.12

instances

Bifunctor

Signature

export declare const Bifunctor: Bifunctor2<'ObservableThese'>

Added in v0.6.12

getApplicative

Signature

export declare const getApplicative: <E>(A: Apply1<R.URI>, S: Semigroup<E>) => Applicative2C<'ObservableThese', E>

Added in v0.6.12

getMonad

Signature

export declare const getMonad: <E>(S: Semigroup<E>) => Monad2C<'ObservableThese', E>

Added in v0.6.12

model

ObservableThese (interface)

Signature

export interface ObservableThese<E, A> extends Observable<TH.These<E, A>> {}

Added in v0.6.12

utils

Functor

Signature

export declare const Functor: Functor2<'ObservableThese'>

Added in v0.6.12

URI

Signature

export declare const URI: 'ObservableThese'

Added in v0.6.12

URI (type alias)

Signature

export type URI = typeof URI

Added in v0.6.12

toTaskThese

Signature

export declare const toTaskThese: <E, A>(o: ObservableThese<E, A>) => TT.TaskThese<E, A>

Added in v0.6.12