TwoWayConverter
interface TwoWayConverter<T, V : AnimationVector>
androidx.compose.animation.core.TwoWayConverter |
TwoWayConverter class contains the definition on how to convert from an arbitrary type T to a AnimationVector, and convert the AnimationVector back to the type T. This allows animations to run on any type of objects, e.g. position, rectangle, color, etc.
Summary
Extension functions | ||
---|---|---|
From androidx.compose.animation.core
|
Properties | |
---|---|
abstract (V) -> T |
Defines how to convert a Vector type (i. |
abstract (T) -> V |
Defines how a type T should be converted to a Vector type (i. |
Properties
convertFromVector
abstract val convertFromVector: (V) -> T
Defines how to convert a Vector type (i.e. AnimationVector1D, AnimationVector2D, AnimationVector3D or AnimationVector4D, depends on the dimensions of type T) back to type T.
convertToVector
abstract val convertToVector: (T) -> V
Defines how a type T should be converted to a Vector type (i.e. AnimationVector1D, AnimationVector2D, AnimationVector3D or AnimationVector4D, depends on the dimensions of type T).