File tree Expand file tree Collapse file tree 18 files changed +67
-26
lines changed
ReactAndroid/src/main/jni/react/jni Expand file tree Collapse file tree 18 files changed +67
-26
lines changed Original file line number Diff line number Diff line change @@ -29,12 +29,16 @@ class Instance;
2929class JavaScriptExecutorHolder ;
3030class NativeArray ;
3131
32- struct JInstanceCallback : public jni ::JavaClass<JInstanceCallback> {
32+ struct [[deprecated(
33+ " This API will be removed along with the legacy architecture." )]] JInstanceCallback
34+ : public jni::JavaClass<JInstanceCallback> {
3335 static constexpr auto kJavaDescriptor =
3436 " Lcom/facebook/react/bridge/CatalystInstanceImpl$InstanceCallback;" ;
3537};
3638
37- class CatalystInstanceImpl : public jni ::HybridClass<CatalystInstanceImpl> {
39+ class [[deprecated(
40+ " This API will be removed along with the legacy architecture." )]] CatalystInstanceImpl
41+ : public jni::HybridClass<CatalystInstanceImpl> {
3842 public:
3943 static constexpr auto kJavaDescriptor =
4044 " Lcom/facebook/react/bridge/CatalystInstanceImpl;" ;
Original file line number Diff line number Diff line change @@ -20,7 +20,9 @@ namespace facebook::react {
2020class Instance ;
2121class MessageQueueThread ;
2222
23- struct JMethodDescriptor : public jni ::JavaClass<JMethodDescriptor> {
23+ struct [[deprecated(
24+ " This API will be removed along with the legacy architecture." )]] JMethodDescriptor
25+ : public jni::JavaClass<JMethodDescriptor> {
2426 static constexpr auto kJavaDescriptor =
2527 " Lcom/facebook/react/bridge/JavaModuleWrapper$MethodDescriptor;" ;
2628
@@ -30,7 +32,9 @@ struct JMethodDescriptor : public jni::JavaClass<JMethodDescriptor> {
3032 std::string getType () const ;
3133};
3234
33- struct JavaModuleWrapper : jni::JavaClass<JavaModuleWrapper> {
35+ struct [[deprecated(
36+ " This API will be removed along with the legacy architecture." )]] JavaModuleWrapper
37+ : jni::JavaClass<JavaModuleWrapper> {
3438 static constexpr auto kJavaDescriptor =
3539 " Lcom/facebook/react/bridge/JavaModuleWrapper;" ;
3640
@@ -59,7 +63,9 @@ struct JavaModuleWrapper : jni::JavaClass<JavaModuleWrapper> {
5963 }
6064};
6165
62- class JavaNativeModule : public NativeModule {
66+ class [[deprecated(
67+ " This API will be removed along with the legacy architecture." )]] JavaNativeModule
68+ : public NativeModule {
6369 public:
6470 JavaNativeModule (
6571 std::weak_ptr<Instance> instance,
Original file line number Diff line number Diff line change 1414
1515namespace facebook ::react {
1616
17- class JavaScriptExecutorHolder
17+ class [[deprecated(
18+ " This API will be removed along with the legacy architecture." )]] JavaScriptExecutorHolder
1819 : public jni::HybridClass<JavaScriptExecutorHolder> {
1920 public:
2021 static constexpr auto kJavaDescriptor =
Original file line number Diff line number Diff line change 1616
1717namespace facebook ::react {
1818
19- class JniJSModulesUnbundle : public JSModulesUnbundle {
19+ class [[deprecated(
20+ " This API will be removed along with the legacy architecture." )]] JniJSModulesUnbundle
21+ : public JSModulesUnbundle {
2022 /* *
2123 * This implementation reads modules as single file from the assets of an apk.
2224 */
Original file line number Diff line number Diff line change @@ -20,7 +20,9 @@ namespace facebook::react {
2020
2121class MessageQueueThread ;
2222
23- class ModuleHolder : public jni ::JavaClass<ModuleHolder> {
23+ class [[deprecated(
24+ " This API will be removed along with the legacy architecture." )]] ModuleHolder
25+ : public jni::JavaClass<ModuleHolder> {
2426 public:
2527 static auto constexpr kJavaDescriptor =
2628 " Lcom/facebook/react/bridge/ModuleHolder;" ;
@@ -30,6 +32,7 @@ class ModuleHolder : public jni::JavaClass<ModuleHolder> {
3032 const std::string& moduleName) const ;
3133};
3234
35+ [[deprecated(" This API will be removed along with the legacy architecture." )]]
3336std::vector<std::unique_ptr<NativeModule>> buildNativeModuleList (
3437 std::weak_ptr<Instance> winstance,
3538 jni::alias_ref<jni::JCollection<JavaModuleWrapper::javaobject>::javaobject>
Original file line number Diff line number Diff line change @@ -23,11 +23,14 @@ class MessageQueueThread;
2323
2424typedef void (*WarnOnUsageLogger)(std::string message);
2525
26+ [[deprecated(" This API will be removed along with the legacy architecture." )]]
2627std::function<void (folly::dynamic)> makeCallback (
2728 std::weak_ptr<Instance> instance,
2829 const folly::dynamic& callbackId);
2930
30- class RN_EXPORT CxxNativeModule : public NativeModule {
31+ class RN_EXPORT [[deprecated(
32+ " This API will be removed along with the legacy architecture." )]] CxxNativeModule
33+ : public NativeModule {
3134 public:
3235 CxxNativeModule (
3336 std::weak_ptr<Instance> instance,
Original file line number Diff line number Diff line change @@ -34,14 +34,17 @@ class MessageQueueThread;
3434class ModuleRegistry ;
3535class RAMBundleRegistry ;
3636
37- struct InstanceCallback {
37+ struct [[deprecated(
38+ " This API will be removed along with the legacy architecture." )]] InstanceCallback {
3839 virtual ~InstanceCallback () = default ;
3940 virtual void onBatchComplete () {}
4041 virtual void incrementPendingJSCalls () {}
4142 virtual void decrementPendingJSCalls () {}
4243};
4344
44- class RN_EXPORT Instance : private jsinspector_modern::InstanceTargetDelegate {
45+ class RN_EXPORT [[deprecated(
46+ " This API will be removed along with the legacy architecture." )]] Instance
47+ : private jsinspector_modern::InstanceTargetDelegate {
4548 public:
4649 ~Instance () override ;
4750 void initializeBridge (
Original file line number Diff line number Diff line change @@ -31,7 +31,8 @@ class RAMBundleRegistry;
3131
3232// This interface describes the delegate interface required by
3333// Executor implementations to call from JS into native code.
34- class ExecutorDelegate {
34+ class [[deprecated(
35+ " This API will be removed along with the legacy architecture." )]] ExecutorDelegate {
3536 public:
3637 virtual ~ExecutorDelegate () = default ;
3738
@@ -48,15 +49,17 @@ class ExecutorDelegate {
4849 folly::dynamic&& args) = 0 ;
4950};
5051
51- class JSExecutorFactory {
52+ class [[deprecated(
53+ " This API will be removed along with the legacy architecture." )]] JSExecutorFactory {
5254 public:
5355 virtual std::unique_ptr<JSExecutor> createJSExecutor (
5456 std::shared_ptr<ExecutorDelegate> delegate,
5557 std::shared_ptr<MessageQueueThread> jsQueue) = 0 ;
5658 virtual ~JSExecutorFactory () = default ;
5759};
5860
59- class RN_EXPORT JSExecutor {
61+ class RN_EXPORT [[deprecated(
62+ " This API will be removed along with the legacy architecture." )]] JSExecutor {
6063 public:
6164 /* *
6265 * Prepares the JS runtime for React Native by installing global variables.
Original file line number Diff line number Diff line change 2323
2424namespace facebook ::react {
2525
26- class RN_EXPORT JSIndexedRAMBundle : public JSModulesUnbundle {
26+ class RN_EXPORT [[deprecated(
27+ " This API will be removed along with the legacy architecture." )]] JSIndexedRAMBundle
28+ : public JSModulesUnbundle {
2729 public:
2830 static std::function<std::unique_ptr<JSModulesUnbundle>(std::string)>
2931 buildFactory ();
Original file line number Diff line number Diff line change 1515
1616namespace facebook ::react {
1717
18- class JSModulesUnbundle {
18+ class [[deprecated(
19+ " This API will be removed along with the legacy architecture." )]] JSModulesUnbundle {
1920 /* *
2021 * Represents the set of JavaScript modules that the application consists of.
2122 * The source code of each module can be retrieved by module ID.
You can’t perform that action at this time.
0 commit comments