initial commit
This commit is contained in:
22
dialer/dialer.go
Normal file
22
dialer/dialer.go
Normal file
@ -0,0 +1,22 @@
|
||||
package dialer
|
||||
|
||||
import (
|
||||
"context"
|
||||
"net"
|
||||
|
||||
"github.com/go-gost/core/metadata"
|
||||
)
|
||||
|
||||
// Transporter is responsible for dialing to the proxy server.
|
||||
type Dialer interface {
|
||||
Init(metadata.Metadata) error
|
||||
Dial(ctx context.Context, addr string, opts ...DialOption) (net.Conn, error)
|
||||
}
|
||||
|
||||
type Handshaker interface {
|
||||
Handshake(ctx context.Context, conn net.Conn, opts ...HandshakeOption) (net.Conn, error)
|
||||
}
|
||||
|
||||
type Multiplexer interface {
|
||||
Multiplex() bool
|
||||
}
|
Reference in New Issue
Block a user