Versions in this module Expand all Collapse all v1 v1.24.4 Aug 19, 2016 Changes in this version + var ErrClosedListener = errors.New("Listener is closed.") + var ErrInvalidConn = errors.New("Invalid Connection.") + var StoppedError = errors.New("Listener stopped") + func Dial(src v2net.Address, dest v2net.Destination) (internet.Connection, error) + func FindFirstValid(list []*AwaitingConnection) int + func ListenWS(address v2net.Address, port v2net.Port) (internet.Listener, error) + type AwaitingConnection struct + func (this *AwaitingConnection) Expired() bool + type Config struct + Cert string + ConnectionReuse bool + DeveloperInsecureSkipVerify bool + Path string + PrivKey string + Pto string + func (this *Config) Apply() + func (this *Config) UnmarshalJSON(data []byte) error + type Connection struct + func NewConnection(dest string, conn *wsconn, manager ConnectionManager) *Connection + func (this *Connection) Close() error + func (this *Connection) LocalAddr() net.Addr + func (this *Connection) Read(b []byte) (int, error) + func (this *Connection) RemoteAddr() net.Addr + func (this *Connection) Reusable() bool + func (this *Connection) SetDeadline(t time.Time) error + func (this *Connection) SetReadDeadline(t time.Time) error + func (this *Connection) SetReusable(reusable bool) + func (this *Connection) SetWriteDeadline(t time.Time) error + func (this *Connection) SysFd() (int, error) + func (this *Connection) Write(b []byte) (int, error) + type ConnectionCache struct + func NewConnectionCache() *ConnectionCache + func (this *ConnectionCache) Cleanup() + func (this *ConnectionCache) Get(dest string) net.Conn + func (this *ConnectionCache) Recycle(dest string, conn *wsconn) + type ConnectionManager interface + Recycle func(string, *wsconn) + type ConnectionWithError struct + type StoppableListener struct + func NewStoppableListener(l net.Listener) (*StoppableListener, error) + func (sl *StoppableListener) Accept() (net.Conn, error) + func (sl *StoppableListener) Stop() + type WSListener struct + func (this *WSListener) Accept() (internet.Connection, error) + func (this *WSListener) Addr() net.Addr + func (this *WSListener) Close() error + func (this *WSListener) Recycle(dest string, conn *wsconn)