BiDiMapping

open class BiDiMapping<IN, OUT>(val clazz: Class<OUT>, val asOut: (IN) -> OUT, val asIn: (OUT) -> IN)

A BiDiMapping defines a reusable bidirectional transformation between an input and output type

Constructors

Link copied to clipboard
constructor(clazz: Class<OUT>, asOut: (IN) -> OUT, asIn: (OUT) -> IN)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val asIn: (OUT) -> IN
Link copied to clipboard
val asOut: (IN) -> OUT
Link copied to clipboard

Functions

Link copied to clipboard
@JvmName(name = "asIn")
operator fun invoke(out: OUT): IN
@JvmName(name = "asOut")
operator fun invoke(asIn: IN): OUT
Link copied to clipboard
inline fun <NEXT> map(crossinline nextOut: (OUT) -> NEXT, crossinline nextIn: (NEXT) -> OUT): BiDiMapping<IN, NEXT>