Kotlinify react/animated interfaces (#45725)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/45725

# Changelog:
[Internal] -

The "interface" classes inside `animated` converted to Kotlin.

Reviewed By: tdn120

Differential Revision: D60284765

fbshipit-source-id: fe7bbecad706e3f58db8304a6bad23d05f999118
This commit is contained in:
Ruslan Shestopalyuk
2024-07-28 23:26:14 -07:00
committed by Facebook GitHub Bot
parent 1e6b9796f7
commit e2de11c824
3 changed files with 16 additions and 8 deletions
@@ -456,6 +456,14 @@ public abstract class com/facebook/react/animated/AnimatedNode {
public final class com/facebook/react/animated/AnimatedNode$Companion {
}
public abstract interface class com/facebook/react/animated/AnimatedNodeValueListener {
public abstract fun onValueUpdate (D)V
}
public abstract interface class com/facebook/react/animated/AnimatedNodeWithUpdateableConfig {
public abstract fun onUpdateConfig (Lcom/facebook/react/bridge/ReadableMap;)V
}
public class com/facebook/react/animated/NativeAnimatedModule : com/facebook/fbreact/specs/NativeAnimatedModuleSpec, com/facebook/react/bridge/LifecycleEventListener, com/facebook/react/bridge/UIManagerListener {
public static final field ANIMATED_MODULE_DEBUG Z
public fun <init> (Lcom/facebook/react/bridge/ReactApplicationContext;)V
@@ -5,9 +5,9 @@
* LICENSE file in the root directory of this source tree.
*/
package com.facebook.react.animated;
package com.facebook.react.animated
/** Interface used to listen to {@link ValueAnimatedNode} updates. */
interface AnimatedNodeValueListener {
void onValueUpdate(double value);
/** Interface used to listen to [ValueAnimatedNode] updates. */
public fun interface AnimatedNodeValueListener {
public fun onValueUpdate(value: Double)
}
@@ -5,11 +5,11 @@
* LICENSE file in the root directory of this source tree.
*/
package com.facebook.react.animated;
package com.facebook.react.animated
import com.facebook.react.bridge.ReadableMap;
import com.facebook.react.bridge.ReadableMap
/** Indicates that AnimatedNode is able to receive native config updates. */
interface AnimatedNodeWithUpdateableConfig {
void onUpdateConfig(ReadableMap config);
public fun interface AnimatedNodeWithUpdateableConfig {
public fun onUpdateConfig(config: ReadableMap?)
}