Documentation ¶
Index ¶
- func Dial(ctx context.Context, dest net.Destination) (internet.Connection, error)
- func Listen(ctx context.Context, address net.Address, port net.Port, ...) (internet.Listener, error)
- type Config
- type Connection
- func (c *Connection) Close() error
- func (c *Connection) LocalAddr() net.Addr
- func (c *Connection) Read(b []byte) (int, error)
- func (c *Connection) RemoteAddr() net.Addr
- func (c *Connection) SetDeadline(t time.Time) error
- func (c *Connection) SetReadDeadline(t time.Time) error
- func (c *Connection) SetWriteDeadline(t time.Time) error
- func (c *Connection) Write(b []byte) (int, error)
- type Listener
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Dial ¶
func Dial(ctx context.Context, dest net.Destination) (internet.Connection, error)
Dial dials a new TCP connection to the given destination.
Types ¶
type Config ¶
type Config struct { Host []string `protobuf:"bytes,1,rep,name=host" json:"host,omitempty"` Path string `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"` }
func (*Config) Descriptor ¶
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
type Connection ¶
type Connection struct { Reader io.Reader Writer io.Writer Closer common.Closable Local net.Addr Remote net.Addr }
func (*Connection) Close ¶
func (c *Connection) Close() error
func (*Connection) LocalAddr ¶
func (c *Connection) LocalAddr() net.Addr
func (*Connection) RemoteAddr ¶
func (c *Connection) RemoteAddr() net.Addr
func (*Connection) SetDeadline ¶
func (c *Connection) SetDeadline(t time.Time) error
func (*Connection) SetReadDeadline ¶
func (c *Connection) SetReadDeadline(t time.Time) error
func (*Connection) SetWriteDeadline ¶
func (c *Connection) SetWriteDeadline(t time.Time) error
Click to show internal directories.
Click to hide internal directories.