Documentation
¶
Index ¶
- type ClientSettings
- type Inbound
- func (i *Inbound) Network() []net.Network
- func (i *Inbound) NewConnection(ctx context.Context, conn net.Conn, metadata M.Metadata) error
- func (i *Inbound) NewError(ctx context.Context, err error)
- func (i *Inbound) NewPacketConnection(ctx context.Context, conn N.PacketConn, metadata M.Metadata) error
- func (i *Inbound) Process(ctx context.Context, conn net.Conn) error
- type Outbound
- type PacketReaderAdaptor
- type PacketWriterAdaptor
- type ServerConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientSettings ¶
type Inbound ¶
type Inbound struct {
// contains filtered or unexported fields
}
func NewServer ¶
func NewServer(config *ServerConfig) (*Inbound, error)
func (*Inbound) NewConnection ¶
func (*Inbound) NewPacketConnection ¶
type Outbound ¶
type Outbound struct {
*ClientSettings
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(config *ClientSettings) (*Outbound, error)
func (*Outbound) HandleFlow ¶
func (o *Outbound) HandleFlow(ctx context.Context, dst net.Destination, rw buf.ReaderWriter) error
func (*Outbound) HandlePacketConn ¶
func (o *Outbound) HandlePacketConn(ctx context.Context, dst net.Destination, p udp.PacketReaderWriter) error
type PacketReaderAdaptor ¶
type PacketReaderAdaptor struct {
network.PacketReader
}
func (*PacketReaderAdaptor) ReadPacket ¶
func (a *PacketReaderAdaptor) ReadPacket() (*udp.Packet, error)
type PacketWriterAdaptor ¶
type PacketWriterAdaptor struct {
network.PacketWriter
}
func (*PacketWriterAdaptor) WritePacket ¶
func (rw *PacketWriterAdaptor) WritePacket(p *udp.Packet) error
Click to show internal directories.
Click to hide internal directories.