Options
All
  • Public
  • Public/Protected
  • All
Menu

Type parameters

  • T

  • R

Hierarchy

  • IFunction

Implemented by

Index

Methods

andThen

  • Returns d composed function that first applies this function to its input, and then applies the after function to the result. If evaluation of either function throws an exceptions, it is relayed to the caller of the composed function.

    type

    V the type of output of the after function, and of the composed function

    Type parameters

    • V

    Parameters

    • after: IFunction<R, V>

      the function to apply after this function is applied

    Returns IFunction<T, V>

    d composed function that first applies this function and then applies the after function

apply

  • apply(t: T): R

compose

  • Returns d composed function that first applies the before function to its input, and then applies this function to the result. If evaluation of either function throws an exceptions, it is relayed to the caller of the composed function.

    type

    V the type of input to the before function, and to the composed function

    Type parameters

    • V

    Parameters

    • before: IFunction<V, T>

      the function to apply before this function is applied

    Returns IFunction<V, R>

    d composed function that first applies the before function and then applies this function

getNativeFunction

  • getNativeFunction(): any

identity

  • Returns d function that always returns its input argument.

    type

    T the type of the input and output objects to the function

    Type parameters

    • T

    Returns IFunction<T, T>

    d function that always returns its input argument

Generated using TypeDoc