Documentation ¶
Overview ¶
Package wrapper is a wrapper around lucas-clemente/quic-go to match the net.Conn based interface used troughout pion/webrtc.
Index ¶
- type Config
- type Listener
- type Session
- type Stream
- func (s *Stream) Close() error
- func (s *Stream) Detach() quic.Stream
- func (s *Stream) Read(p []byte) (int, error)
- func (s *Stream) ReadQuic(p []byte) (int, bool, error)
- func (s *Stream) StreamID() uint64
- func (s *Stream) Write(p []byte, fin bool) (int, error)
- func (s *Stream) WriteQuic(p []byte, fin bool) (int, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Certificate *x509.Certificate PrivateKey crypto.PrivateKey SkipVerify bool }
Config represents the configuration of a Quic session
type Listener ¶
type Listener struct {
// contains filtered or unexported fields
}
A Listener for incoming QUIC connections
type Session ¶
type Session struct {
// contains filtered or unexported fields
}
A Session is a QUIC connection between two peers.
func (*Session) AcceptStream ¶
AcceptStream accepts an incoming stream
func (*Session) CloseWithError ¶
CloseWithError closes the connection with an error. The error must not be nil.
func (*Session) GetRemoteCertificates ¶
func (s *Session) GetRemoteCertificates() []*x509.Certificate
GetRemoteCertificates returns the certificate chain presented by remote peer.
func (*Session) OpenStream ¶
OpenStream opens a new stream
type Stream ¶
type Stream struct {
// contains filtered or unexported fields
}
Stream represents a wrapped quic-go stream
func (*Stream) Close ¶
Close implements the Conn Close method. It is used to close the connection. Any calls to Read and Write will be unblocked and return an error.