Skip to content

Commit

Permalink
[all] Update to AndroidX annotation (#1095)
Browse files Browse the repository at this point in the history
  • Loading branch information
tobrun authored and Langston Smith committed Jan 8, 2020
1 parent d5d5b4f commit a541525
Show file tree
Hide file tree
Showing 86 changed files with 176 additions and 178 deletions.
15 changes: 7 additions & 8 deletions gradle/dependencies.gradle
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
ext {

version = [
autoValue : '1.6.2',
autoValue : '1.7',
autoValueGson : '0.8.0',
junit : '4.12',
supportLibVersion: '27.1.1',
gson : '2.8.5',
retrofit : '2.4.0',
okhttp3 : '3.11.0',
mockito : '2.18.3',
annotation : '1.0.0',
gson : '2.8.6',
retrofit : '2.7.1',
okhttp3 : '3.12.7',
mockito : '2.28.2',
hamcrestJunit : '2.0.0.0',
errorprone : '2.3.1',
]
Expand All @@ -29,7 +29,7 @@ ext {
autoValue : "com.google.auto.value:auto-value:${version.autoValue}",
autoValueGson : "com.ryanharter.auto.value:auto-value-gson:${version.autoValueGson}",
junit : "junit:junit:${version.junit}",
supportAnnotation : "com.android.support:support-annotations:${version.supportLibVersion}",
supportAnnotation : "androidx.annotation:annotation:${version.annotation}",
gson : "com.google.code.gson:gson:${version.gson}",
retrofit : "com.squareup.retrofit2:retrofit:${version.retrofit}",
retrofit2Gson : "com.squareup.retrofit2:converter-gson:${version.retrofit}",
Expand All @@ -41,7 +41,6 @@ ext {
errorprone : "com.google.errorprone:error_prone_core:${version.errorprone}"
]


pluginDependencies = [
checkstyle : "com.puppycrawl.tools:checkstyle:${pluginVersion.checkstyle}",
spotbugs : "gradle.plugin.com.github.spotbugs:gradlePlugin:${pluginVersion.spotbugs}",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.mapbox.core.internal;

import static android.support.annotation.RestrictTo.Scope.LIBRARY_GROUP;
import static androidx.annotation.RestrictTo.Scope.LIBRARY_GROUP;

import android.support.annotation.RestrictTo;
import androidx.annotation.RestrictTo;

/**
* Contains simple precondition checks.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.core.utils;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.mapbox.core.constants.Constants;

import java.util.Locale;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directionsrefresh.v1;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directionsrefresh.v1.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5;

import android.support.annotation.StringDef;
import androidx.annotation.StringDef;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.mapbox.api.directions.v5;

import android.support.annotation.FloatRange;
import android.support.annotation.IntRange;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.FloatRange;
import androidx.annotation.IntRange;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directions.v5;

import android.support.annotation.FloatRange;
import android.support.annotation.Nullable;
import androidx.annotation.FloatRange;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.annotation.StringDef;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.StringDef;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand All @@ -18,7 +18,7 @@

/**
* A part of the {@link BannerText} which includes a snippet of the full banner text instruction. In
* cases where data is avaliable, an image url will be provided to visually include a road shield.
* cases where data is available, an image url will be provided to visually include a road shield.
* To receive this information, your request must have {@link MapboxDirections#bannerInstructions()}
* set to true.
*
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand All @@ -12,6 +9,9 @@

import java.util.List;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

/**
* Includes both plain text information that can be visualized inside your navigation application
* along with the text string broken down into {@link BannerComponents} which may or may not
Expand All @@ -34,7 +34,7 @@ public static Builder builder() {
}

/**
* Plain text with all the {@link BannerComponents} text combined.
* Plain text with all the {@link BannerComponents} text combined.BannerInstructions.
*
* @return plain text with all the {@link BannerComponents} text items combined
* @since 5.0.0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.TypeAdapter;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.FloatRange;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.annotation.StringDef;
import androidx.annotation.FloatRange;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.StringDef;

import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.directions.v5.models;

import android.support.annotation.Nullable;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.geocoding.v5;

import android.support.annotation.StringDef;
import androidx.annotation.StringDef;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.mapbox.api.geocoding.v5;

import android.support.annotation.FloatRange;
import android.support.annotation.IntRange;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.FloatRange;
import androidx.annotation.IntRange;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.google.auto.value.AutoValue;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.geocoding.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package com.mapbox.api.geocoding.v5.models;

import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.api.geocoding.v5.models;

import android.support.annotation.NonNull;
import androidx.annotation.NonNull;
import com.google.auto.value.AutoValue;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

package com.google.gson.typeadapters;

import android.support.annotation.Keep;
import androidx.annotation.Keep;

import java.io.IOException;
import java.util.LinkedHashMap;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.geojson;

import android.support.annotation.Keep;
import androidx.annotation.Keep;

import com.google.gson.TypeAdapter;
import com.google.gson.stream.JsonReader;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.geojson;

import android.support.annotation.Keep;
import androidx.annotation.Keep;

import com.google.gson.Gson;
import com.google.gson.TypeAdapter;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import static com.mapbox.geojson.constants.GeoJsonConstants.MIN_LATITUDE;
import static com.mapbox.geojson.constants.GeoJsonConstants.MIN_LONGITUDE;

import android.support.annotation.FloatRange;
import android.support.annotation.Keep;
import android.support.annotation.NonNull;
import androidx.annotation.FloatRange;
import androidx.annotation.Keep;
import androidx.annotation.NonNull;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.TypeAdapter;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.mapbox.geojson;

import android.support.annotation.Keep;
import androidx.annotation.Keep;

/**
* Each of the s geometries which make up GeoJson implement this interface and consume a varying
Expand Down
Loading

0 comments on commit a541525

Please sign in to comment.