AICC is a library for Checking internet connection and open setting Screen for connecting internet via Wifi and Mobile Data.
Step 1. Add the JitPack repository to your build file. Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Step 2. Add the dependency
dependencies {
implementation 'com.github.gafurcseku:internet-connectivity-checker:1.0.1'
}
if(NetworkUtil.isConnected(this)){
/// Connection is Available
}else{
/// Connection is not Available
}
if(NetworkUtil.isConnected(this)){
/// Connection is Available
}else{
/// Connection is not Available
}
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.