Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidFrame = errors.New("invalid frame type")
ErrInvalidFrame is returned when writing invalid frame type.
Functions ¶
This section is empty.
Types ¶
type Conn ¶
type Conn interface { FrameReader FrameWriter io.Closer URL() url.URL LocalAddr() net.Addr RemoteAddr() net.Addr RemoteHeader() http.Header SetReadDeadline(t time.Time) error SetWriteDeadline(t time.Time) error }
Conn is a transport connection.
type ConnParameters ¶
type ConnParameters struct { PingInterval time.Duration PingTimeout time.Duration SID string Upgrades []string }
ConnParameters is connection parameter of server.
func ReadConnParameters ¶
func ReadConnParameters(r io.Reader) (ConnParameters, error)
ReadConnParameters reads ConnParameters from r.
type FrameReader ¶
FrameReader reads a frame. It need be closed before next reading.
type FrameWriter ¶
FrameWriter writes a frame. It need be closed before next writing.
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager is a manager of transports.
func NewManager ¶
NewManager creates a new manager.
func (*Manager) UpgradeFrom ¶
UpgradeFrom returns a name list of transports which can upgrade from given name.
Click to show internal directories.
Click to hide internal directories.