smithy4s.Transformation
See theTransformation companion object
Heterogenous function construct, allows to abstract over various kinds of functions whilst providing an homogenous user experience without the user having to manually lift functions from one kind to the other.
// assuming Foo is a code-generated interface
val fooOption: Foo[Option] = ???
val toList = new smithy4s.PolyFunction[Option, List]{def apply[A](fa: Option[A]): List[A] = fa.toList}
val fooList: Foo[List] = foo.transform(toList)
It is possible to plug arbitrary transformations to mechanism, such as cats.arrow.FunctionK
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
Members list
In this article