Reader

interface Reader<E, A> {
    @@type: string;
    ap<B>(rfn: monet.Reader<E, ((val: A) => B)>): monet.Reader<E, B>;
    apTo<B>(value: monet.Reader<E, B>): A extends ((arg: B) => any)
        ? monet.Reader<E, ReturnType<A<A>>>
        : never;
    bind<B>(fn: ((val: A) => monet.Reader<E, B>)): monet.Reader<E, B>;
    chain<B>(fn: ((val: A) => monet.Reader<E, B>)): monet.Reader<E, B>;
    fantasy-land/ap?<V>(afn: monet.Applicative<((val: A) => V)>): monet.Applicative<V>;
    fantasy-land/chain?<V>(fn: ((val: A) => monet.Chain<V>)): monet.Chain<V>;
    fantasy-land/map?<V>(fn: ((val: A) => V)): monet.Functor<V>;
    flatMap<B>(fn: ((val: A) => monet.Reader<E, B>)): monet.Reader<E, B>;
    join<B>(): monet.Reader<E, B>;
    local<X>(fn: ((val: X) => E)): monet.Reader<X, A>;
    map<B>(fn: ((val: A) => B)): monet.Reader<E, B>;
    run(config: E): A;
    takeLeft<X>(m: monet.Reader<E, X>): monet.Reader<E, A>;
    takeRight<B>(m: monet.Reader<E, B>): monet.Reader<E, B>;
}

Type Parameters

  • E
  • A

Hierarchy-Diagram

UML class diagram of Reader
Legend
icon for an interface in the UML class diagram interface
icon for a public method in the UML class diagram public method

Hierarchy (view full)

Properties

@@type: string

Methods

  • Type Parameters

    • X

    Parameters

    • fn: ((val: X) => E)
        • (val: X): E
        • Parameters

          • val: X

          Returns E

    Returns monet.Reader<X, A>

  • Type Parameters

    • B

    Parameters

    • fn: ((val: A) => B)
        • (val: A): B
        • Parameters

          • val: A

          Returns B

    Returns monet.Reader<E, B>

  • Parameters

    • config: E

    Returns A