Refine aggregator

This commit is contained in:
Mygod
2019-08-12 13:01:37 +08:00
parent 5b3de2fda6
commit 05a79acf78
6 changed files with 31 additions and 40 deletions

View File

@@ -5,12 +5,12 @@ import be.mygod.vpnhotspot.net.IpNeighbour
import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor
abstract class IpNeighbourMonitoringService : Service(), IpNeighbourMonitor.Callback {
private var neighbours = emptyList<IpNeighbour>()
private var neighbours: Collection<IpNeighbour> = emptyList()
protected abstract val activeIfaces: List<String>
protected open val inactiveIfaces get() = emptyList<String>()
override fun onIpNeighbourAvailable(neighbours: List<IpNeighbour>) {
override fun onIpNeighbourAvailable(neighbours: Collection<IpNeighbour>) {
this.neighbours = neighbours
updateNotification()
}