mirror of
https://github.com/bettercap/bettercap
synced 2025-08-19 21:13:18 -07:00
refact: renamed package net to network to avoid collision with golang net package.
This commit is contained in:
parent
21236c257e
commit
48d27f274a
28 changed files with 298 additions and 298 deletions
|
@ -1,12 +1,12 @@
|
|||
package modules
|
||||
|
||||
import (
|
||||
"github.com/evilsocket/bettercap-ng/net"
|
||||
"github.com/evilsocket/bettercap-ng/network"
|
||||
"github.com/evilsocket/bettercap-ng/packets"
|
||||
"github.com/evilsocket/bettercap-ng/session"
|
||||
)
|
||||
|
||||
type ByAddressSorter []*net.Endpoint
|
||||
type ByAddressSorter []*network.Endpoint
|
||||
|
||||
func (a ByAddressSorter) Len() int { return len(a) }
|
||||
func (a ByAddressSorter) Swap(i, j int) { a[i], a[j] = a[j], a[i] }
|
||||
|
@ -17,13 +17,13 @@ func (a ByAddressSorter) Less(i, j int) bool {
|
|||
return a[i].IpAddressUint32 < a[j].IpAddressUint32
|
||||
}
|
||||
|
||||
type BySeenSorter []*net.Endpoint
|
||||
type BySeenSorter []*network.Endpoint
|
||||
|
||||
func (a BySeenSorter) Len() int { return len(a) }
|
||||
func (a BySeenSorter) Swap(i, j int) { a[i], a[j] = a[j], a[i] }
|
||||
func (a BySeenSorter) Less(i, j int) bool { return a[i].LastSeen.After(a[j].LastSeen) }
|
||||
|
||||
type BySentSorter []*net.Endpoint
|
||||
type BySentSorter []*network.Endpoint
|
||||
|
||||
func (a BySentSorter) Len() int { return len(a) }
|
||||
func (a BySentSorter) Swap(i, j int) { a[i], a[j] = a[j], a[i] }
|
||||
|
@ -46,7 +46,7 @@ func (a BySentSorter) Less(i, j int) bool {
|
|||
return bTraffic.Sent < aTraffic.Sent
|
||||
}
|
||||
|
||||
type ByRcvdSorter []*net.Endpoint
|
||||
type ByRcvdSorter []*network.Endpoint
|
||||
|
||||
func (a ByRcvdSorter) Len() int { return len(a) }
|
||||
func (a ByRcvdSorter) Swap(i, j int) { a[i], a[j] = a[j], a[i] }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue