From 178f8095ca8ac4f90f8ed9a66ea1e32e42ee2c92 Mon Sep 17 00:00:00 2001 From: Frieder Bluemle Date: Thu, 21 Nov 2019 11:07:31 -0800 Subject: [PATCH] Migrate to androidx --- android/electrode-reactnative-bridge/build.gradle | 9 +++++---- .../electrode/reactnative/bridge/BaseBridgeTestCase.java | 7 ++++--- .../electrode/reactnative/bridge/BridgeHolderTests.java | 4 ++-- .../bridge/ElectrodeBridgeTransceiverTest.java | 5 +++-- .../electrode/reactnative/bridge/EventProcessorTest.java | 2 +- .../electrode/reactnative/bridge/RequestHandleTests.java | 6 +++--- .../reactnative/bridge/RequestProcessorTest.java | 5 +++-- .../electrode/reactnative/sample/api/PersonApi.java | 2 +- .../electrode/reactnative/sample/api/PersonEvents.java | 2 +- .../electrode/reactnative/sample/api/PersonRequests.java | 2 +- .../reactnative/sample/api/UpdatePersonRequestData.java | 5 +++-- .../electrode/reactnative/sample/model/Address.java | 5 +++-- .../electrode/reactnative/sample/model/BirthYear.java | 4 ++-- .../electrode/reactnative/sample/model/Person.java | 5 +++-- .../electrode/reactnative/sample/model/Position.java | 9 ++++----- .../electrode/reactnative/sample/model/Status.java | 9 ++++----- .../reactnative/bridge/BridgeFailureMessage.java | 4 ++-- .../electrode/reactnative/bridge/BridgeMessage.java | 5 +++-- .../electrode/reactnative/bridge/BridgeTransaction.java | 4 ++-- .../electrode/reactnative/bridge/Bridgeable.java | 3 ++- .../electrode/reactnative/bridge/ConstantsProvider.java | 2 +- .../reactnative/bridge/ElectrodeBridgeEvent.java | 5 +++-- .../reactnative/bridge/ElectrodeBridgeEventListener.java | 2 +- .../reactnative/bridge/ElectrodeBridgeHolder.java | 4 ++-- .../reactnative/bridge/ElectrodeBridgeRequest.java | 4 ++-- .../bridge/ElectrodeBridgeRequestHandler.java | 4 ++-- .../reactnative/bridge/ElectrodeBridgeResponse.java | 5 +++-- .../bridge/ElectrodeBridgeResponseListener.java | 4 ++-- .../reactnative/bridge/ElectrodeBridgeTransceiver.java | 7 ++++--- .../reactnative/bridge/ElectrodeNativeBridge.java | 4 ++-- .../reactnative/bridge/ElectrodeReactBridge.java | 2 +- .../electrode/reactnative/bridge/EventDispatcher.java | 2 +- .../reactnative/bridge/EventDispatcherImpl.java | 2 +- .../reactnative/bridge/EventListenerProcessor.java | 4 ++-- .../electrode/reactnative/bridge/EventProcessor.java | 6 ++---- .../electrode/reactnative/bridge/EventRegistrar.java | 2 +- .../electrode/reactnative/bridge/EventRegistrarImpl.java | 4 ++-- .../reactnative/bridge/ExistingHandlerException.java | 2 +- .../electrode/reactnative/bridge/FailureMessage.java | 4 ++-- .../walmartlabs/electrode/reactnative/bridge/None.java | 3 ++- .../reactnative/bridge/ReactContextWrapper.java | 2 +- .../reactnative/bridge/ReactContextWrapperInternal.java | 2 +- .../electrode/reactnative/bridge/RequestDispatcher.java | 2 +- .../reactnative/bridge/RequestDispatcherImpl.java | 4 ++-- .../reactnative/bridge/RequestHandlerProcessor.java | 4 ++-- .../electrode/reactnative/bridge/RequestProcessor.java | 4 ++-- .../electrode/reactnative/bridge/RequestRegistrar.java | 4 ++-- .../reactnative/bridge/RequestRegistrarImpl.java | 6 +++--- .../reactnative/bridge/helpers/ArgumentsEx.java | 6 +++--- .../reactnative/bridge/util/BridgeArguments.java | 7 ++++--- android/gradle.properties | 9 +++++++-- 51 files changed, 117 insertions(+), 102 deletions(-) diff --git a/android/electrode-reactnative-bridge/build.gradle b/android/electrode-reactnative-bridge/build.gradle index 534cd4ef..7c62c89e 100644 --- a/android/electrode-reactnative-bridge/build.gradle +++ b/android/electrode-reactnative-bridge/build.gradle @@ -27,7 +27,7 @@ android { ndk { abiFilters "armeabi-v7a", "x86" } - testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner' + testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } buildTypes { release { @@ -43,9 +43,10 @@ android { dependencies { api fileTree(dir: 'libs', include: ['*.jar']) - implementation 'com.android.support:appcompat-v7:28.0.0' + implementation 'androidx.appcompat:appcompat:1.2.0' + implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0' implementation 'com.facebook.react:react-native:+' androidTestImplementation 'junit:junit:4.12' - androidTestImplementation 'com.android.support.test:runner:1.0.2' - androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' + androidTestImplementation 'androidx.test.ext:junit:1.1.1' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' } diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BaseBridgeTestCase.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BaseBridgeTestCase.java index c3ac1c3f..6f76c359 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BaseBridgeTestCase.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BaseBridgeTestCase.java @@ -19,9 +19,10 @@ import android.app.Instrumentation; import android.os.Handler; import android.os.Looper; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; -import android.support.test.InstrumentationRegistry; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.test.platform.app.InstrumentationRegistry; import com.facebook.react.ReactInstanceManager; import com.facebook.react.bridge.Arguments; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BridgeHolderTests.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BridgeHolderTests.java index 6e0f9f3e..23b840b2 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BridgeHolderTests.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/BridgeHolderTests.java @@ -1,7 +1,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiverTest.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiverTest.java index 8f4da64e..42289359 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiverTest.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiverTest.java @@ -17,8 +17,9 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReactContextBaseJavaModule; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessorTest.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessorTest.java index 6268bb67..4f0f5f71 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessorTest.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessorTest.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.Nullable; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.sample.api.PersonApi; import com.walmartlabs.electrode.reactnative.sample.model.Person; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandleTests.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandleTests.java index 0bc0c9da..6b177fa0 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandleTests.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandleTests.java @@ -1,7 +1,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.sample.api.PersonApi; @@ -166,7 +166,7 @@ public void onSuccess(@Nullable Integer responseData) { @Override public void onFailure(@NonNull FailureMessage failureMessage) { - fail(); + fail(); } }); diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessorTest.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessorTest.java index 0516a58e..49366969 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessorTest.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessorTest.java @@ -17,8 +17,9 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReadableArray; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonApi.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonApi.java index ec533bac..f5a2067b 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonApi.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonApi.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.sample.api; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.walmartlabs.electrode.reactnative.bridge.ElectrodeBridgeEventListener; import com.walmartlabs.electrode.reactnative.bridge.ElectrodeBridgeRequestHandler; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonEvents.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonEvents.java index 55e376d6..e0b5e00d 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonEvents.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonEvents.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.sample.api; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.walmartlabs.electrode.reactnative.bridge.ElectrodeBridgeEventListener; import com.walmartlabs.electrode.reactnative.bridge.EventListenerProcessor; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonRequests.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonRequests.java index 5349c711..d9d7e137 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonRequests.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/PersonRequests.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.sample.api; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.walmartlabs.electrode.reactnative.bridge.ElectrodeBridgeRequestHandler; import com.walmartlabs.electrode.reactnative.bridge.ElectrodeBridgeResponseListener; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/UpdatePersonRequestData.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/UpdatePersonRequestData.java index a3fb1d52..54759717 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/UpdatePersonRequestData.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/api/UpdatePersonRequestData.java @@ -17,8 +17,9 @@ package com.walmartlabs.electrode.reactnative.sample.api; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; import com.walmartlabs.electrode.reactnative.sample.model.Status; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Address.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Address.java index 92f587ee..2e8e712e 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Address.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Address.java @@ -19,8 +19,9 @@ import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/BirthYear.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/BirthYear.java index aba21fd7..b769ccdb 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/BirthYear.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/BirthYear.java @@ -19,8 +19,8 @@ import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Person.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Person.java index e5904153..ce17be29 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Person.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Person.java @@ -19,8 +19,9 @@ import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Position.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Position.java index 0f1eb3a9..803741dd 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Position.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Position.java @@ -19,12 +19,11 @@ import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; -import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; -import static com.walmartlabs.electrode.reactnative.bridge.util.BridgeArguments.getNumberValue; +import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; public class Position implements Parcelable, Bridgeable { @@ -88,7 +87,7 @@ public void writeToParcel(Parcel dest, int flags) { public Bundle toBundle() { Bundle bundle = new Bundle(); bundle.putDouble("lat", lat); - if(lng != null) { + if (lng != null) { bundle.putDouble("lng", lng); } return bundle; diff --git a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Status.java b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Status.java index aa33c1cc..8ae34c16 100644 --- a/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Status.java +++ b/android/electrode-reactnative-bridge/src/androidTest/java/com/walmartlabs/electrode/reactnative/sample/model/Status.java @@ -19,12 +19,11 @@ import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; -import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; -import static com.walmartlabs.electrode.reactnative.bridge.util.BridgeArguments.getNumberValue; +import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; public class Status implements Parcelable, Bridgeable { @@ -97,7 +96,7 @@ public void writeToParcel(Parcel dest, int flags) { @NonNull public Bundle toBundle() { Bundle bundle = new Bundle(); - if(log != null) { + if (log != null) { bundle.putBoolean("log", log); } bundle.putBoolean("member", member); diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeFailureMessage.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeFailureMessage.java index 8a7e2402..d0499c1c 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeFailureMessage.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeFailureMessage.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; public class BridgeFailureMessage implements FailureMessage { diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeMessage.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeMessage.java index a364d70a..1c129adb 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeMessage.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeMessage.java @@ -17,8 +17,9 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReadableMap; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeTransaction.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeTransaction.java index 1e2faed8..4e5afeca 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeTransaction.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/BridgeTransaction.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; public class BridgeTransaction { diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/Bridgeable.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/Bridgeable.java index 88a38a1d..8c5f9c74 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/Bridgeable.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/Bridgeable.java @@ -17,7 +17,8 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; + +import androidx.annotation.NonNull; /** * Indicates that any class that implements this interface can be sent across the ElectrodeNativeBridge. diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ConstantsProvider.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ConstantsProvider.java index 92425cec..1689e23e 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ConstantsProvider.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ConstantsProvider.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.Nullable; +import androidx.annotation.Nullable; import java.util.Map; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEvent.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEvent.java index da46ff86..c9650868 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEvent.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEvent.java @@ -17,8 +17,9 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.facebook.react.bridge.ReadableMap; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEventListener.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEventListener.java index f6bdaf71..fbed5357 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEventListener.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeEventListener.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.Nullable; +import androidx.annotation.Nullable; /** * Provide method to be notified of incoming event diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeHolder.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeHolder.java index 2e51e361..67fbe48b 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeHolder.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeHolder.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequest.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequest.java index 2df53a50..abda7880 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequest.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequest.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.facebook.react.bridge.ReadableMap; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequestHandler.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequestHandler.java index 1acc2c84..f4eac473 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequestHandler.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeRequestHandler.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; /** * Provide method to be notified of incoming request. diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponse.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponse.java index 51c83e85..ad8d6e8d 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponse.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponse.java @@ -17,8 +17,9 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReadableMap; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponseListener.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponseListener.java index fa10897f..ac3529d1 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponseListener.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeResponseListener.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; /** * Provide methods to report response for a request. diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiver.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiver.java index e5022327..e08871d9 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiver.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeBridgeTransceiver.java @@ -18,9 +18,10 @@ import android.os.Handler; import android.os.Looper; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; -import android.support.annotation.VisibleForTesting; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.annotation.VisibleForTesting; import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.bridge.ReactContextBaseJavaModule; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeNativeBridge.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeNativeBridge.java index ed0c9a4d..846bd540 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeNativeBridge.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeNativeBridge.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import java.util.UUID; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeReactBridge.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeReactBridge.java index 5d35ccbe..b07e81ea 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeReactBridge.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ElectrodeReactBridge.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.facebook.react.bridge.ReadableMap; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcher.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcher.java index c9ec2091..a38eede2 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcher.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcher.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; public interface EventDispatcher { void dispatchEvent(@NonNull ElectrodeBridgeEvent event); diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcherImpl.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcherImpl.java index 9ac8495b..00de6279 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcherImpl.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventDispatcherImpl.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventListenerProcessor.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventListenerProcessor.java index 9939f371..2c1d92d9 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventListenerProcessor.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventListenerProcessor.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; import com.walmartlabs.electrode.reactnative.bridge.util.BridgeArguments; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessor.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessor.java index 96b13b9a..59c7115f 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessor.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventProcessor.java @@ -16,13 +16,11 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; -import java.util.UUID; - /** * Processes an event that is emitted from Native side * diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrar.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrar.java index 88501513..5902ac59 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrar.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrar.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import java.util.List; import java.util.UUID; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrarImpl.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrarImpl.java index a88b04bb..5509c821 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrarImpl.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/EventRegistrarImpl.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.VisibleForTesting; +import androidx.annotation.NonNull; +import androidx.annotation.VisibleForTesting; import java.util.ArrayList; import java.util.Collections; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ExistingHandlerException.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ExistingHandlerException.java index 431da80f..742ada02 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ExistingHandlerException.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ExistingHandlerException.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; /** * Exception thrown when trying to register a request handler for a request name that already diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/FailureMessage.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/FailureMessage.java index de8632e8..e2a46095 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/FailureMessage.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/FailureMessage.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; /** * Bridge failure message interface. diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/None.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/None.java index ec019d1d..6cebef5a 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/None.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/None.java @@ -17,7 +17,8 @@ package com.walmartlabs.electrode.reactnative.bridge; import android.os.Bundle; -import android.support.annotation.NonNull; + +import androidx.annotation.NonNull; /** * Class that is used to represent an emplty request or response type. diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapper.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapper.java index e5b23da4..09511355 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapper.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapper.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.facebook.react.bridge.ReactApplicationContext; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapperInternal.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapperInternal.java index 84622076..9978a3f4 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapperInternal.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/ReactContextWrapperInternal.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.facebook.react.bridge.ReactApplicationContext; import com.facebook.react.modules.core.DeviceEventManagerModule; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcher.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcher.java index 9f90803e..de846090 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcher.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcher.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; public interface RequestDispatcher { diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcherImpl.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcherImpl.java index 673a4a04..eb1132cf 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcherImpl.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestDispatcherImpl.java @@ -16,7 +16,7 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; +import androidx.annotation.NonNull; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; @@ -46,7 +46,7 @@ public void dispatchRequest(@NonNull final ElectrodeBridgeRequest bridgeRequest, responseListener.onFailure(failureMessage); return; } - requestHandler.onRequest(bridgeRequest,responseListener); + requestHandler.onRequest(bridgeRequest, responseListener); } diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandlerProcessor.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandlerProcessor.java index be3a1dc0..b94d1468 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandlerProcessor.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestHandlerProcessor.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; import com.walmartlabs.electrode.reactnative.bridge.util.BridgeArguments; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessor.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessor.java index d90b02a1..4c966c69 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessor.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestProcessor.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; import com.walmartlabs.electrode.reactnative.bridge.util.BridgeArguments; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrar.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrar.java index 12a943a7..54f6869b 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrar.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrar.java @@ -16,8 +16,8 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; import java.util.UUID; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrarImpl.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrarImpl.java index 821369f2..d52403c6 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrarImpl.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/RequestRegistrarImpl.java @@ -16,9 +16,9 @@ package com.walmartlabs.electrode.reactnative.bridge; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; -import android.support.annotation.VisibleForTesting; +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.annotation.VisibleForTesting; import com.walmartlabs.electrode.reactnative.bridge.helpers.Logger; diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/helpers/ArgumentsEx.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/helpers/ArgumentsEx.java index cc55652c..7fc900dc 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/helpers/ArgumentsEx.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/helpers/ArgumentsEx.java @@ -17,7 +17,8 @@ package com.walmartlabs.electrode.reactnative.bridge.helpers; import android.os.Bundle; -import android.support.annotation.NonNull; + +import androidx.annotation.NonNull; import com.facebook.react.bridge.Arguments; import com.facebook.react.bridge.ReadableArray; @@ -25,7 +26,6 @@ import com.facebook.react.bridge.ReadableMapKeySetIterator; import com.facebook.react.bridge.ReadableType; import com.facebook.react.bridge.WritableMap; -import com.walmartlabs.electrode.reactnative.bridge.BridgeMessage; import javax.annotation.Nullable; @@ -137,7 +137,7 @@ public static Bundle toBundle(@Nullable ReadableMap readableMap) { break; case Array: { ReadableArray readableArray = readableMap.getArray(key); - if(readableArray.size() > 0) { + if (readableArray.size() > 0) { switch (readableArray.getType(0)) { case String: bundle.putStringArray(key, ArgumentsEx.toStringArray(readableArray)); diff --git a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/util/BridgeArguments.java b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/util/BridgeArguments.java index 100ca462..d4470cc8 100644 --- a/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/util/BridgeArguments.java +++ b/android/electrode-reactnative-bridge/src/main/java/com/walmartlabs/electrode/reactnative/bridge/util/BridgeArguments.java @@ -17,9 +17,10 @@ package com.walmartlabs.electrode.reactnative.bridge.util; import android.os.Bundle; -import android.support.annotation.NonNull; -import android.support.annotation.Nullable; -import android.support.annotation.VisibleForTesting; + +import androidx.annotation.NonNull; +import androidx.annotation.Nullable; +import androidx.annotation.VisibleForTesting; import com.walmartlabs.electrode.reactnative.bridge.BridgeMessage; import com.walmartlabs.electrode.reactnative.bridge.Bridgeable; diff --git a/android/gradle.properties b/android/gradle.properties index 78f5b567..ba2d76be 100644 --- a/android/gradle.properties +++ b/android/gradle.properties @@ -16,7 +16,12 @@ org.gradle.jvmargs=-Xmx1536m # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects # org.gradle.parallel=true -android.useDeprecatedNdk=true +# AndroidX package structure to make it clearer which packages are bundled with the +# Android operating system, and which are packaged with your app's APK +# https://developer.android.com/topic/libraries/support-library/androidx-rn +android.useAndroidX=true +# Automatically convert third-party libraries to use AndroidX +android.enableJetifier=true mavenUser= -mavenPassword= \ No newline at end of file +mavenPassword=