diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/IpNeighbourMonitoringService.kt b/mobile/src/main/java/be/mygod/vpnhotspot/IpNeighbourMonitoringService.kt index 92ac4d1a..2e0f7826 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/IpNeighbourMonitoringService.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/IpNeighbourMonitoringService.kt @@ -1,8 +1,8 @@ package be.mygod.vpnhotspot import android.app.Service -import be.mygod.vpnhotspot.net.IpNeighbour -import be.mygod.vpnhotspot.net.IpNeighbourMonitor +import be.mygod.vpnhotspot.net.monitor.IpNeighbour +import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor abstract class IpNeighbourMonitoringService : Service(), IpNeighbourMonitor.Callback { private var neighbours = emptyList() diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyHotspotService.kt b/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyHotspotService.kt index 8c072492..035a1246 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyHotspotService.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyHotspotService.kt @@ -6,7 +6,7 @@ import android.net.wifi.WifiManager import androidx.annotation.RequiresApi import be.mygod.vpnhotspot.App.Companion.app import be.mygod.vpnhotspot.manage.LocalOnlyHotspotManager -import be.mygod.vpnhotspot.net.IpNeighbourMonitor +import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor import be.mygod.vpnhotspot.net.TetheringManager import be.mygod.vpnhotspot.util.broadcastReceiver import be.mygod.vpnhotspot.widget.SmartSnackbar diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyInterfaceManager.kt b/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyInterfaceManager.kt index d97e1f1c..dc4c5e9b 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyInterfaceManager.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/LocalOnlyInterfaceManager.kt @@ -3,7 +3,7 @@ package be.mygod.vpnhotspot import android.content.Context import be.mygod.vpnhotspot.App.Companion.app import be.mygod.vpnhotspot.net.Routing -import be.mygod.vpnhotspot.net.UpstreamMonitor +import be.mygod.vpnhotspot.net.monitor.UpstreamMonitor import be.mygod.vpnhotspot.widget.SmartSnackbar import timber.log.Timber import java.net.InetAddress diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/SettingsPreferenceFragment.kt b/mobile/src/main/java/be/mygod/vpnhotspot/SettingsPreferenceFragment.kt index 882be58b..ac74c114 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/SettingsPreferenceFragment.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/SettingsPreferenceFragment.kt @@ -12,7 +12,7 @@ import androidx.preference.Preference import androidx.preference.SwitchPreference import be.mygod.vpnhotspot.App.Companion.app import be.mygod.vpnhotspot.net.Routing -import be.mygod.vpnhotspot.net.UpstreamMonitor +import be.mygod.vpnhotspot.net.monitor.UpstreamMonitor import be.mygod.vpnhotspot.preference.AlwaysAutoCompleteEditTextPreferenceDialogFragmentCompat import be.mygod.vpnhotspot.preference.SharedPreferenceDataStore import be.mygod.vpnhotspot.util.RootSession diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/TetheringService.kt b/mobile/src/main/java/be/mygod/vpnhotspot/TetheringService.kt index f7dc0677..740a343f 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/TetheringService.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/TetheringService.kt @@ -4,10 +4,10 @@ import android.content.Intent import android.content.IntentFilter import be.mygod.vpnhotspot.App.Companion.app import be.mygod.vpnhotspot.manage.TetheringFragment -import be.mygod.vpnhotspot.net.IpNeighbourMonitor +import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor import be.mygod.vpnhotspot.net.Routing import be.mygod.vpnhotspot.net.TetheringManager -import be.mygod.vpnhotspot.net.UpstreamMonitor +import be.mygod.vpnhotspot.net.monitor.UpstreamMonitor import be.mygod.vpnhotspot.util.broadcastReceiver import be.mygod.vpnhotspot.widget.SmartSnackbar import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/client/Client.kt b/mobile/src/main/java/be/mygod/vpnhotspot/client/Client.kt index aa75ddf4..07153997 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/client/Client.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/client/Client.kt @@ -10,7 +10,7 @@ import androidx.recyclerview.widget.DiffUtil import be.mygod.vpnhotspot.App.Companion.app import be.mygod.vpnhotspot.R import be.mygod.vpnhotspot.net.InetAddressComparator -import be.mygod.vpnhotspot.net.IpNeighbour +import be.mygod.vpnhotspot.net.monitor.IpNeighbour import be.mygod.vpnhotspot.net.TetherType import be.mygod.vpnhotspot.room.AppDatabase import be.mygod.vpnhotspot.room.lookup diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientMonitorService.kt b/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientMonitorService.kt index bd6ff7b0..5637d7eb 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientMonitorService.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientMonitorService.kt @@ -5,8 +5,8 @@ import android.content.* import android.net.wifi.p2p.WifiP2pDevice import android.os.IBinder import be.mygod.vpnhotspot.RepeaterService -import be.mygod.vpnhotspot.net.IpNeighbour -import be.mygod.vpnhotspot.net.IpNeighbourMonitor +import be.mygod.vpnhotspot.net.monitor.IpNeighbour +import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor import be.mygod.vpnhotspot.net.TetheringManager import be.mygod.vpnhotspot.util.StickyEvent1 import be.mygod.vpnhotspot.util.broadcastReceiver diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientsFragment.kt b/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientsFragment.kt index 5553dce4..3e341ded 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientsFragment.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/client/ClientsFragment.kt @@ -27,8 +27,8 @@ import be.mygod.vpnhotspot.BR import be.mygod.vpnhotspot.R import be.mygod.vpnhotspot.databinding.FragmentClientsBinding import be.mygod.vpnhotspot.databinding.ListitemClientBinding -import be.mygod.vpnhotspot.net.IpNeighbourMonitor -import be.mygod.vpnhotspot.net.TrafficRecorder +import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor +import be.mygod.vpnhotspot.net.monitor.TrafficRecorder import be.mygod.vpnhotspot.room.* import be.mygod.vpnhotspot.util.ServiceForegroundConnector import be.mygod.vpnhotspot.util.toPluralInt diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/client/TetheringClient.kt b/mobile/src/main/java/be/mygod/vpnhotspot/client/TetheringClient.kt index c6d65092..d88d6fa1 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/client/TetheringClient.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/client/TetheringClient.kt @@ -1,6 +1,6 @@ package be.mygod.vpnhotspot.client -import be.mygod.vpnhotspot.net.IpNeighbour +import be.mygod.vpnhotspot.net.monitor.IpNeighbour class TetheringClient(private val neighbour: IpNeighbour) : Client() { override val iface get() = neighbour.dev diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt index b967897d..308b9a60 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt @@ -11,6 +11,7 @@ import be.mygod.vpnhotspot.R import be.mygod.vpnhotspot.client.Client import be.mygod.vpnhotspot.client.ClientMonitorService import be.mygod.vpnhotspot.debugLog +import be.mygod.vpnhotspot.net.monitor.TrafficRecorder import be.mygod.vpnhotspot.util.RootSession import be.mygod.vpnhotspot.util.computeIfAbsentCompat import be.mygod.vpnhotspot.util.stopAndUnbind diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/InterfaceMonitor.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/InterfaceMonitor.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/InterfaceMonitor.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/InterfaceMonitor.kt index 40ced8f9..ae78b50a 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/InterfaceMonitor.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/InterfaceMonitor.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor import be.mygod.vpnhotspot.App.Companion.app diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpMonitor.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpMonitor.kt index e721892e..1f831b70 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpMonitor.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpMonitor.kt @@ -1,6 +1,5 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor -import android.util.Log import be.mygod.vpnhotspot.R import be.mygod.vpnhotspot.util.thread import be.mygod.vpnhotspot.widget.SmartSnackbar diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbour.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbour.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbour.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbour.kt index 57877e3d..b8b15a1f 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbour.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbour.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor import be.mygod.vpnhotspot.util.parseNumericAddressNoThrow import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbourMonitor.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbourMonitor.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbourMonitor.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbourMonitor.kt index 37ecbede..3ef37d3d 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbourMonitor.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbourMonitor.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor import be.mygod.vpnhotspot.App.Companion.app import be.mygod.vpnhotspot.debugLog diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/TrafficRecorder.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TrafficRecorder.kt similarity index 99% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/TrafficRecorder.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TrafficRecorder.kt index 27c6f5ca..90a4fd1f 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/TrafficRecorder.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TrafficRecorder.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor import android.os.SystemClock import android.util.LongSparseArray diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/UpstreamMonitor.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/UpstreamMonitor.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/UpstreamMonitor.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/UpstreamMonitor.kt index 2cf7aa1c..9487b6c7 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/UpstreamMonitor.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/UpstreamMonitor.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor import android.content.SharedPreferences import be.mygod.vpnhotspot.App.Companion.app diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/VpnMonitor.kt b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/VpnMonitor.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/VpnMonitor.kt rename to mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/VpnMonitor.kt index adbbc934..587a0a06 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/VpnMonitor.kt +++ b/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/VpnMonitor.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package be.mygod.vpnhotspot.net.monitor import android.net.ConnectivityManager import android.net.Network