mirror of
https://gitee.com/konyshe/goodlink.git
synced 2025-09-27 13:02:08 +08:00
18 lines
382 B
Go
18 lines
382 B
Go
package netstack
|
|
|
|
import (
|
|
"gvisor.dev/gvisor/pkg/tcpip/stack"
|
|
)
|
|
|
|
// Device is the interface that implemented by network layer devices (e.g. tun),
|
|
// and easy to use as stack.LinkEndpoint.
|
|
type Device interface {
|
|
stack.LinkEndpoint
|
|
|
|
// Name returns the current name of the device.
|
|
Name() string
|
|
|
|
// Type returns the driver type of the device.
|
|
Type() string
|
|
}
|