Documentation ¶
Index ¶
- Constants
- func QuiclyCloseEngine() int
- func QuiclyInitializeEngine(options types.Options) int
- type QClientSession
- func (s *QClientSession) Accept() (net.Conn, error)
- func (s *QClientSession) Addr() net.Addr
- func (s *QClientSession) Close() error
- func (s *QClientSession) GetStream(id uint64) types.Stream
- func (s *QClientSession) ID() uint64
- func (s *QClientSession) OnStreamClose(streamId uint64, error int)
- func (s *QClientSession) OnStreamOpen(streamId uint64)
- func (s *QClientSession) OpenStream() types.Stream
- func (s *QClientSession) StreamPacket(packet *types.Packet)
- type QServerConnection
- func (r *QServerConnection) Accept() (types.Stream, error)
- func (r *QServerConnection) Addr() net.Addr
- func (r *QServerConnection) Close() error
- func (r *QServerConnection) GetStream(id uint64) types.Stream
- func (r *QServerConnection) ID() uint64
- func (r *QServerConnection) OnStreamClose(streamId uint64, code int)
- func (r *QServerConnection) OnStreamOpen(streamId uint64)
- func (r *QServerConnection) OpenStream() types.Stream
- func (r *QServerConnection) StreamPacket(packet *types.Packet)
- type QServerSession
- func (s *QServerSession) Accept() (types.ServerConnection, error)
- func (s *QServerSession) Addr() net.Addr
- func (s *QServerSession) Close() error
- func (s *QServerSession) GetStream(id uint64) types.Stream
- func (s *QServerSession) ID() uint64
- func (s *QServerSession) OnStreamClose(streamId uint64, error int)
- func (s *QServerSession) OnStreamOpen(streamId uint64)
- func (s *QServerSession) OpenStream() types.Stream
- func (s *QServerSession) StreamPacket(packet *types.Packet)
- type QStream
- func (s *QStream) Close() error
- func (s *QStream) ID() uint64
- func (s *QStream) IsClosed() bool
- func (s *QStream) LocalAddr() net.Addr
- func (s *QStream) OnClosed() error
- func (s *QStream) OnOpened()
- func (s *QStream) OnReceived(data []byte, dataLen int)
- func (s *QStream) Read(b []byte) (n int, err error)
- func (s *QStream) RemoteAddr() net.Addr
- func (s *QStream) SetDeadline(t time.Time) error
- func (s *QStream) SetReadDeadline(t time.Time) error
- func (s *QStream) SetWriteDeadline(t time.Time) error
- func (s *QStream) Write(b []byte) (n int, err error)
Constants ¶
View Source
const ( READ_SIZE = 512 * 1024 SMALL_BUFFER_SIZE = 4 * 1024 )
View Source
const (
MAX_CONNECTIONS = 8192
)
Variables ¶
This section is empty.
Functions ¶
func QuiclyCloseEngine ¶
func QuiclyCloseEngine() int
func QuiclyInitializeEngine ¶
Types ¶
type QClientSession ¶
type QClientSession struct { // exported fields Conn *net.UDPConn Ctx context.Context Logger log.Logger // callback types.Callbacks // contains filtered or unexported fields }
func (*QClientSession) Addr ¶
func (s *QClientSession) Addr() net.Addr
func (*QClientSession) Close ¶
func (s *QClientSession) Close() error
func (*QClientSession) ID ¶
func (s *QClientSession) ID() uint64
func (*QClientSession) OnStreamClose ¶
func (s *QClientSession) OnStreamClose(streamId uint64, error int)
func (*QClientSession) OnStreamOpen ¶
func (s *QClientSession) OnStreamOpen(streamId uint64)
func (*QClientSession) OpenStream ¶
func (s *QClientSession) OpenStream() types.Stream
func (*QClientSession) StreamPacket ¶
func (s *QClientSession) StreamPacket(packet *types.Packet)
type QServerConnection ¶
type QServerConnection struct { // exported fields Ctx context.Context NetConn *net.UDPConn Logger log.Logger // contains filtered or unexported fields }
func (*QServerConnection) Addr ¶
func (r *QServerConnection) Addr() net.Addr
func (*QServerConnection) Close ¶
func (r *QServerConnection) Close() error
func (*QServerConnection) ID ¶
func (r *QServerConnection) ID() uint64
func (*QServerConnection) OnStreamClose ¶
func (r *QServerConnection) OnStreamClose(streamId uint64, code int)
func (*QServerConnection) OnStreamOpen ¶
func (r *QServerConnection) OnStreamOpen(streamId uint64)
func (*QServerConnection) OpenStream ¶
func (r *QServerConnection) OpenStream() types.Stream
func (*QServerConnection) StreamPacket ¶
func (r *QServerConnection) StreamPacket(packet *types.Packet)
type QServerSession ¶
type QServerSession struct { // exported fields NetConn *net.UDPConn Ctx context.Context Logger log.Logger // callback types.Callbacks // contains filtered or unexported fields }
func (*QServerSession) Accept ¶
func (s *QServerSession) Accept() (types.ServerConnection, error)
func (*QServerSession) Addr ¶
func (s *QServerSession) Addr() net.Addr
func (*QServerSession) Close ¶
func (s *QServerSession) Close() error
func (*QServerSession) ID ¶
func (s *QServerSession) ID() uint64
func (*QServerSession) OnStreamClose ¶
func (s *QServerSession) OnStreamClose(streamId uint64, error int)
func (*QServerSession) OnStreamOpen ¶
func (s *QServerSession) OnStreamOpen(streamId uint64)
func (*QServerSession) OpenStream ¶
func (s *QServerSession) OpenStream() types.Stream
func (*QServerSession) StreamPacket ¶
func (s *QServerSession) StreamPacket(packet *types.Packet)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.