api

http4k / org.http4k.lens / LensInjector

LensInjector

interface LensInjector<in IN, in OUT> (source)

Functions

Name Summary
inject open fun <R : OUT> inject(value: IN, target: R): R
Lens operation to set the value into the target. Synomym for invoke(IN, OUT)
invoke abstract operator fun <R : OUT> invoke(value: IN, target: R): R
Lens operation to set the value into the target
of open infix fun <R : OUT> of(value: IN): (R) -> R
Bind this Lens to a value, so we can set it into a target
set open operator fun <R : OUT> set(target: R, value: IN): R
Lens operation to set the value into the target. Synomym for invoke(IN, OUT)

Extension Functions

Name Summary
with fun <T> T.with(vararg modifiers: (T) -> T): T

Inheritors

Name Summary
BiDiBodyLens class BiDiBodyLens<FINAL> : LensInjector<FINAL, HttpMessage>, BodyLens<FINAL>
A BiDiBodyLens provides the bi-directional extraction of an entity from a target body, or the insertion of an entity into a target body.
BiDiLens class BiDiLens<in IN : Any, FINAL> : LensInjector<FINAL, IN>, Lens<IN, FINAL>
A BiDiLens provides the bi-directional extraction of an entity from a target, or the insertion of an entity into a target.
BiDiPathLens class BiDiPathLens<FINAL> : LensInjector<FINAL, Request>, PathLens<FINAL>
Companion companion object Companion : LensExtractor<Request, UUID>, LensInjector<UUID, Request>
Store interface Store<OUT> : LensInjector<OUT, Request>, LensExtractor<Request, OUT>