Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Transport ¶
func Transport(fn func(t transport.Transport) error, options *websocket.AcceptOptions) http.HandlerFunc
Transport returns a http.HandlerFunc that wraps a websocket setup/teardown into a transport.Transport which sends and receives JSON packets. The transport.Transport provides a context which represents the socket; use its own context only if you're fine with waiting forever while the connection is open. The handler should return a websocket.CloseError to emit a specfic state to the caller.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.