@FunctionalInterface interface Function1<A : Any!, R : Any!> : Serializable
Represents a function with a single argument.
static val serialVersionUID: Long |
open fun <R2 : Any!> andThen(after: (in R) -> out R2): ((A) -> R2)!
Returns a composed function that first applies this function to the given input and then applies the function passed as after to the result. |
|
abstract fun apply(value: A): R
Applies this function to the given argument. |
|
open fun <A2 : Any!> compose(before: (in A2) -> out A): ((A2) -> R)!
Returns a composed function that first applies the before function and then applies itself to the result. |
|
open static fun <T1 : Any!, R : Any!> constant(value: R): ((T1) -> R)!
Returns a function that always returns the constant regardless of the passed arguments. |
|
open static fun <T : Any!> identity(): ((T) -> T)!
Returns a function that always returns its input argument. |
|
open static fun <L : Any!, R : Any!> liftTry(partial: (in L) -> out R): ((L) -> Try<R>!)!
Lifts given |