http4k / org.http4k.lens / 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.
Name | Summary |
---|---|
<init> | A BiDiBodyLens provides the bi-directional extraction of an entity from a target body, or the insertion of an entity into a target body.BiDiBodyLens(metas: List < Meta >, contentType: ContentType , get: ( HttpMessage ) -> FINAL, setLens: (FINAL, HttpMessage ) -> HttpMessage ) |
Name | Summary |
---|---|
invoke | Lens operation to set the value into the targetoperator fun <R : HttpMessage > invoke(value: FINAL, target: R): R |
Name | Summary |
---|---|
asResult | Convert the result of a lens extraction to a Result4k type whichfun <IN, OUT> LensExtractor <IN, OUT>.asResult(): LensExtractor <IN, Result<OUT, LensFailure >> |