package uz.mobiuz.mobiservice.dev.utils

import android.content.BroadcastReceiver
import android.content.Context
import android.content.Intent
import android.util.Log
import uz.mobiuz.mobiservice.dev.ui.global.CONSTANTS

class NetworkChangeReceiver : BroadcastReceiver() {
    override fun onReceive(context: Context, intent: Intent) {
        val status = NetworkUtil.getConnectivityStatusString(context)
        if (CONSTANTS.CONNECTIVITY_CHANGE == intent.action) {
            if (status == NetworkUtil.NETWORK_STATUS_NOT_CONNECTED) {
                Log.e("AAA", "NETWORK_STATUS_NOT_CONNECTED")
            } else {
                Log.e("AAA", "ELSE ")
            }
        }
    }
}