1. La forma convencional de implementar clases internas anónimas
valueAnimator.addUpdateListener(object :AnimatorUpdateListener {
override fun onAnimationUpdate(animation: ValueAnimator?) {
currentPoint = animation?.animatedValue as Point
postInvalidate()
}
})
2. Clase interna anónima de la versión de expresión lambda
valueAnimator.addUpdateListener { animation ->
currentPoint = animation?.animatedValue as Point
postInvalidate()
}