mirror of
https://github.com/SagerNet/sing-box.git
synced 2024-12-27 18:55:38 +08:00
15 lines
389 B
Go
15 lines
389 B
Go
package adapter
|
|
|
|
import (
|
|
"context"
|
|
"net"
|
|
|
|
N "github.com/sagernet/sing/common/network"
|
|
)
|
|
|
|
type ConnectionManager interface {
|
|
Lifecycle
|
|
NewConnection(ctx context.Context, this N.Dialer, conn net.Conn, metadata InboundContext, onClose N.CloseHandlerFunc)
|
|
NewPacketConnection(ctx context.Context, this N.Dialer, conn N.PacketConn, metadata InboundContext, onClose N.CloseHandlerFunc)
|
|
}
|