Documentation
¶
Overview ¶
Package common contains things shared by client and server
Index ¶
- func DialURL(u *url.URL, ctx context.Context, ...) (net.Conn, error)
- func GenerateTLSConfig() *tls.Config
- type QuicConn
- func (q *QuicConn) Close() error
- func (q *QuicConn) LocalAddr() net.Addr
- func (q *QuicConn) Read(b []byte) (n int, err error)
- func (q *QuicConn) RemoteAddr() net.Addr
- func (q *QuicConn) SetDeadline(t time.Time) error
- func (q *QuicConn) SetReadDeadline(t time.Time) error
- func (q *QuicConn) SetWriteDeadline(t time.Time) error
- func (q *QuicConn) Write(b []byte) (n int, err error)
- type QuicListener
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateTLSConfig ¶
Setup a bare-bones TLS config for the server
Types ¶
type QuicConn ¶
QuicConn wraps a conn and a single stream and implements net.Conn
func NewQuicConn ¶
NewQuicConn creates a new QuicConn with the provided connection and stream. Both conn and stream must be non-nil.
func (*QuicConn) RemoteAddr ¶
RemoteAddr implements net.Conn
func (*QuicConn) SetDeadline ¶
SetDeadline implements net.Conn
func (*QuicConn) SetReadDeadline ¶
SetReadDeadline implements net.Conn
func (*QuicConn) SetWriteDeadline ¶
SetWriteDeadline implements net.Conn
type QuicListener ¶
QuicListener implements net.Listener
func (*QuicListener) Accept ¶
func (l *QuicListener) Accept() (net.Conn, error)
Accept implements net.Listener. It starts a single QUIC Stream and returns a QuicConn that implements net.Conn for this single Stream.
func (*QuicListener) Addr ¶
func (l *QuicListener) Addr() net.Addr
func (*QuicListener) Close ¶
func (l *QuicListener) Close() error
Click to show internal directories.
Click to hide internal directories.