-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathElementaryTurboModule.java
More file actions
35 lines (28 loc) · 920 Bytes
/
ElementaryTurboModule.java
File metadata and controls
35 lines (28 loc) · 920 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package com.elementary;
import androidx.annotation.NonNull;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.bridge.Promise;
import com.elementary.NativeElementarySpec;
public class ElementaryTurboModule extends NativeElementarySpec {
private final ElementaryModule module;
public ElementaryTurboModule(ReactApplicationContext reactContext) {
super(reactContext);
module = new ElementaryModule(reactContext);
}
@Override
public void getSampleRate(Promise promise) {
module.getSampleRate(promise);
}
@Override
public void applyInstructions(String message) {
module.applyInstructions(message);
}
@Override
public void addListener(String eventName) {
module.addListener(eventName);
}
@Override
public void removeListeners(double count) {
module.removeListeners(count);
}
}