forked from facebook/react-native
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enable module annotation processor in OSS
- Loading branch information
1 parent
63208dd
commit 4927b5b
Showing
29 changed files
with
137 additions
and
143 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 3 additions & 6 deletions
9
ReactAndroid/src/main/java/com/facebook/react/module/annotations/BUCK
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,14 @@ | ||
load("//tools/build_defs/oss:rn_defs.bzl", "react_native_dep", "react_native_target", "rn_android_library") | ||
load("//tools/build_defs/oss:rn_defs.bzl", "rn_android_library") | ||
|
||
rn_android_library( | ||
name = "annotations", | ||
srcs = glob(["**/*.java"]), | ||
autoglob = False, | ||
labels = ["supermodule:xplat/default/public.react_native.infra"], | ||
required_for_source_only_abi = True, | ||
visibility = [ | ||
"PUBLIC", | ||
], | ||
deps = [ | ||
react_native_dep("third-party/java/infer-annotations:infer-annotations"), | ||
react_native_dep("third-party/java/jsr-305:jsr-305"), | ||
react_native_target("java/com/facebook/react/bridge:interfaces"), | ||
exported_deps = [ | ||
"//packages/annotations-compiler/annotations/src/main/java/com/facebook/react/module/annotations:annotations", | ||
], | ||
) |
7 changes: 3 additions & 4 deletions
7
ReactAndroid/src/main/java/com/facebook/react/module/model/BUCK
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,13 @@ | ||
load("//tools/build_defs/oss:rn_defs.bzl", "react_native_dep", "rn_android_library") | ||
load("//tools/build_defs/oss:rn_defs.bzl", "rn_android_library") | ||
|
||
rn_android_library( | ||
name = "model", | ||
srcs = glob(["**/*.java"]), | ||
autoglob = False, | ||
labels = ["supermodule:xplat/default/public.react_native.infra"], | ||
visibility = [ | ||
"PUBLIC", | ||
], | ||
deps = [ | ||
react_native_dep("third-party/java/jsr-305:jsr-305"), | ||
exported_deps = [ | ||
"//packages/annotations-compiler/annotations/src/main/java/com/facebook/react/module/model:model", | ||
], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
/* | ||
* Copyright (c) Facebook, Inc. and its affiliates. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
|
||
apply plugin: 'java' | ||
|
||
dependencies { | ||
|
||
} | ||
|
||
java { | ||
sourceCompatibility(JavaVersion.VERSION_1_8) | ||
targetCompatibility(JavaVersion.VERSION_1_8) | ||
} |
12 changes: 12 additions & 0 deletions
12
...annotations-compiler/annotations/src/main/java/com/facebook/react/module/annotations/BUCK
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
load("//tools/build_defs/oss:rn_defs.bzl", "react_native_dep", "react_native_target", "rn_android_library") | ||
|
||
rn_android_library( | ||
name = "annotations", | ||
srcs = glob(["**/*.java"]), | ||
autoglob = False, | ||
labels = ["supermodule:xplat/default/public.react_native.infra"], | ||
required_for_source_only_abi = True, | ||
visibility = [ | ||
"PUBLIC", | ||
], | ||
) |
15 changes: 15 additions & 0 deletions
15
...ler/annotations/src/main/java/com/facebook/react/module/annotations/BaseNativeModule.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* | ||
* Copyright (c) Facebook, Inc. and its affiliates. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
|
||
package com.facebook.react.module.annotations; | ||
|
||
/** | ||
* Used to make sure classes passed to the ReactModule annotation are actually an instance of | ||
* NativeModule without needing a dependency on NativeModule that is in the ReactAndroid target. | ||
*/ | ||
public interface BaseNativeModule { | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
packages/annotations-compiler/annotations/src/main/java/com/facebook/react/module/model/BUCK
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
load("//tools/build_defs/oss:rn_defs.bzl", "react_native_dep", "rn_android_library") | ||
|
||
rn_android_library( | ||
name = "model", | ||
srcs = glob(["**/*.java"]), | ||
autoglob = False, | ||
labels = ["supermodule:xplat/default/public.react_native.infra"], | ||
visibility = [ | ||
"PUBLIC", | ||
], | ||
) |
File renamed without changes.
File renamed without changes.
Oops, something went wrong.