Refactor TAGs

This commit is contained in:
Adeel Zafar 2019-08-11 14:59:20 +05:00
parent a847783a61
commit 3bb7b40be4
3 changed files with 5 additions and 5 deletions

View File

@ -61,7 +61,8 @@ public class ZimHostActivity extends BaseActivity implements
public static final String ACTION_IS_HOTSPOT_ENABLED = "Is_hotspot_enabled";
public static final String ACTION_START_SERVER = "start_server";
public static final String ACTION_STOP_SERVER = "stop_server";
private final String IP_STATE_KEY = "ip_state_key";
private static final String IP_STATE_KEY = "ip_state_key";
private static final String TAG = "ZimHostActivity";
private static final int MY_PERMISSIONS_ACCESS_FINE_LOCATION = 102;
private static final int LOCATION_SETTINGS_PERMISSION_RESULT = 101;
private Intent serviceIntent;
@ -69,7 +70,6 @@ public class ZimHostActivity extends BaseActivity implements
HotspotService hotspotService;
String ip;
boolean bound;
String TAG = ZimHostActivity.this.getClass().getSimpleName();
ServiceConnection serviceConnection;
@Override
@ -191,7 +191,7 @@ public class ZimHostActivity extends BaseActivity implements
method.setAccessible(true);
return (Boolean) method.invoke(cm);
} catch (Exception e) {
Log.e("ZimHostActivity", e.toString());
Log.e(TAG, e.toString());
}
return false;
}

View File

@ -36,6 +36,7 @@ import static org.kiwix.kiwixmobile.webserver.ZimHostActivity.ACTION_TURN_ON_AFT
public class HotspotService extends Service {
private static final int HOTSPOT_NOTIFICATION_ID = 666;
private static final String ACTION_STOP = "hotspot_stop";
private static final String TAG = "HotspotService";
private WifiHotspotManager hotspotManager;
private BroadcastReceiver stopReceiver;
private NotificationManager notificationManager;
@ -43,7 +44,6 @@ public class HotspotService extends Service {
ServerStateListener serverStateListener;
IBinder serviceBinder = new HotspotBinder();
WebServerHelper webServerHelper;
String TAG = HotspotService.this.getClass().getSimpleName();
@Override public void onCreate() {

View File

@ -21,7 +21,7 @@ public class WifiHotspotManager {
WifiManager.LocalOnlyHotspotReservation hotspotReservation;
boolean oreoenabled;
WifiConfiguration currentConfig;
String TAG = WifiHotspotManager.this.getClass().getSimpleName();
private static final String TAG = "WifiHotspotManager";
public WifiHotspotManager(Context context) {
this.context = context;