NamedFunction2

com.phasmidsoftware.lascala.fp.NamedFunction2
See theNamedFunction2 companion object
class NamedFunction2[-T1, -T2, +R](val name: String, val f: (T1, T2) => R) extends (T1, T2) => R, Named

NamedFunction2 class.

Type parameters

R

the result type

T1

the input type

T2

the input type

Value parameters

f

the function itself

name

the name of this function

Attributes

Companion
object
Graph
Supertypes
trait Named
trait (T1, T2) => R
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

override def apply(t1: T1, t2: T2): R

Applies the body of this function to the arguments.

Applies the body of this function to the arguments.

Value parameters

v1

the 1st argument of type T1

v2

the 2nd argument of type T2

Attributes

Returns

the result of function application.

Definition Classes
Function2
override def curried: NamedFunction[T1, T2 => R]

Creates a curried version of this function.

Creates a curried version of this function.

Attributes

Returns

a function f such that f(x1)(x2) == apply(x1, x2)

Definition Classes
Function2
override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Named -> Function2 -> Any
override def tupled: NamedFunction[(T1, T2), R]

Creates a tupled version of this function: instead of 2 arguments, it accepts a single scala.Tuple2 argument.

Creates a tupled version of this function: instead of 2 arguments, it accepts a single scala.Tuple2 argument.

Attributes

Returns

a function f such that f((x1, x2)) == f(Tuple2(x1, x2)) == apply(x1, x2)

Definition Classes
Function2

Concrete fields

val f: (T1, T2) => R
val name: String

Provide the name of an object, primarily for rendering/debugging purposes.

Provide the name of an object, primarily for rendering/debugging purposes.

Attributes

Returns

the name

Inherited fields

val sCurried: String

Attributes

Inherited from:
Named
val sTupled: String

Attributes

Inherited from:
Named