Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Function2Static

This is the type of the Function2 constant, which offers some helper functions to deal with Function2 including the ability to build Function2 from functions using Function2Static.of. It also offers some builtin functions like Function2Static.constant.

Hierarchy

  • Function2Static

Index

Methods

Methods

constant

  • constant<T1, T2, R>(val: R): Function2<T1, T2, R>
  • The constant function of two parameters: will always return the value you give, no matter the parameters it's given.

    Type parameters

    • T1

    • T2

    • R

    Parameters

    • val: R

    Returns Function2<T1, T2, R>

of

  • of<T1, T2, R>(fn: function): Function2<T1, T2, R>
  • Take a two-parameter function and lift it to become a Function2, enabling you to call Function2.andThen and other such methods on it.

    Type parameters

    • T1

    • T2

    • R

    Parameters

    • fn: function
        • (x: T1, y: T2): R
        • Parameters

          • x: T1
          • y: T2

          Returns R

    Returns Function2<T1, T2, R>

Generated using TypeDoc