aboutsummaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2019-06-07 13:11:45 -0400
committerAllan Wang <me@allanwang.ca>2019-06-07 13:11:45 -0400
commit77be91c57b36ae85b6be34d3db864fcd63661018 (patch)
treeed5a31772d4c59f072f51afde12ae91d71b877dc /core
parente3a8afc8ec7e99899303de5dc715a1c4ef8fb675 (diff)
downloadkau-77be91c57b36ae85b6be34d3db864fcd63661018.tar.gz
kau-77be91c57b36ae85b6be34d3db864fcd63661018.tar.bz2
kau-77be91c57b36ae85b6be34d3db864fcd63661018.zip
Add deprecation annotations for network utils
Diffstat (limited to 'core')
-rw-r--r--core/src/main/kotlin/ca/allanwang/kau/utils/NetworkUtils.kt3
1 files changed, 3 insertions, 0 deletions
diff --git a/core/src/main/kotlin/ca/allanwang/kau/utils/NetworkUtils.kt b/core/src/main/kotlin/ca/allanwang/kau/utils/NetworkUtils.kt
index 32cf084..39d689b 100644
--- a/core/src/main/kotlin/ca/allanwang/kau/utils/NetworkUtils.kt
+++ b/core/src/main/kotlin/ca/allanwang/kau/utils/NetworkUtils.kt
@@ -22,6 +22,7 @@ import android.net.ConnectivityManager
/**
* Created by Allan Wang on 2017-07-07.
*/
+@Suppress("DEPRECATION")
@Deprecated("Applications should make use of network callbacks instead of individual queries")
inline val Context.isNetworkAvailable: Boolean
@SuppressLint("MissingPermission")
@@ -31,6 +32,7 @@ inline val Context.isNetworkAvailable: Boolean
return activeNetworkInfo?.isConnectedOrConnecting ?: false
}
+@Suppress("DEPRECATION")
@Deprecated("Applications should make use of network callbacks instead of individual queries")
inline val Context.isWifiConnected: Boolean
@SuppressLint("MissingPermission")
@@ -40,6 +42,7 @@ inline val Context.isWifiConnected: Boolean
return (activeNetworkInfo?.type ?: -1) == ConnectivityManager.TYPE_WIFI
}
+@Suppress("DEPRECATION")
@Deprecated("Applications should make use of network callbacks instead of individual queries")
inline val Context.isMobileDataConnected: Boolean
@SuppressLint("MissingPermission")