package utils
Import Path
github.com/quic-go/quic-go/internal/utils (on go.dev )
Dependency Relation
imports 11 packages , and imported by 7 packages
Package-Level Type Names (total 5)
/* sort by: alphabet | popularity */
type ConnectionStats (struct)
ConnectionStats stores stats for the connection. See the public
ConnectionStats struct in connection.go for more information
Fields (total 6 )
BytesLost atomic .Uint64
BytesReceived atomic .Uint64
BytesSent atomic .Uint64
PacketsLost atomic .Uint64
PacketsReceived atomic .Uint64
PacketsSent atomic .Uint64
As Inputs Of (at least 2 )
func github.com/quic-go/quic-go/internal/ackhandler.NewSentPacketHandler (initialPN protocol .PacketNumber , initialMaxDatagramSize protocol .ByteCount , rttStats *RTTStats , connStats *ConnectionStats , clientAddressValidated bool , enableECN bool , ignorePacketsBelow func(protocol .PacketNumber ), pers protocol .Perspective , qlogger qlogwriter .Recorder , logger Logger ) ackhandler .SentPacketHandler
func github.com/quic-go/quic-go/internal/congestion.NewCubicSender (clock congestion .Clock , rttStats *RTTStats , connStats *ConnectionStats , initialMaxDatagramSize protocol .ByteCount , reno bool , qlogger qlogwriter .Recorder ) *congestion .cubicSender
type Logger (interface)
A Logger logs.
Methods (total 7 )
( Logger) Debug () bool
( Logger) Debugf (format string , args ...any )
( Logger) Errorf (format string , args ...any )
( Logger) Infof (format string , args ...any )
( Logger) SetLogLevel (LogLevel )
( Logger) SetLogTimeFormat (format string )
( Logger) WithPrefix (prefix string ) Logger
Implements (at least one exported )
Logger : github.com/stretchr/testify/assert.TestingT
As Outputs Of (at least one exported )
func Logger.WithPrefix (prefix string ) Logger
As Inputs Of (at least 9 )
func github.com/quic-go/quic-go/internal/ackhandler.NewReceivedPacketHandler (logger Logger ) *ackhandler .ReceivedPacketHandler
func github.com/quic-go/quic-go/internal/ackhandler.NewSentPacketHandler (initialPN protocol .PacketNumber , initialMaxDatagramSize protocol .ByteCount , rttStats *RTTStats , connStats *ConnectionStats , clientAddressValidated bool , enableECN bool , ignorePacketsBelow func(protocol .PacketNumber ), pers protocol .Perspective , qlogger qlogwriter .Recorder , logger Logger ) ackhandler .SentPacketHandler
func github.com/quic-go/quic-go/internal/flowcontrol.NewConnectionFlowController (receiveWindow protocol .ByteCount , maxReceiveWindow protocol .ByteCount , allowWindowIncrease func(size protocol .ByteCount ) bool , rttStats *RTTStats , logger Logger ) *flowcontrol .connectionFlowController
func github.com/quic-go/quic-go/internal/flowcontrol.NewStreamFlowController (streamID protocol .StreamID , cfc flowcontrol .ConnectionFlowController , receiveWindow protocol .ByteCount , maxReceiveWindow protocol .ByteCount , initialSendWindow protocol .ByteCount , rttStats *RTTStats , logger Logger ) flowcontrol .StreamFlowController
func github.com/quic-go/quic-go/internal/handshake.NewCryptoSetupClient (connID protocol .ConnectionID , tp *wire .TransportParameters , tlsConf *tls .Config , enable0RTT bool , rttStats *RTTStats , qlogger qlogwriter .Recorder , logger Logger , version protocol .Version ) handshake .CryptoSetup
func github.com/quic-go/quic-go/internal/handshake.NewCryptoSetupServer (connID protocol .ConnectionID , localAddr, remoteAddr net .Addr , tp *wire .TransportParameters , tlsConf *tls .Config , allow0RTT bool , rttStats *RTTStats , qlogger qlogwriter .Recorder , logger Logger , version protocol .Version ) handshake .CryptoSetup
func github.com/quic-go/quic-go/internal/wire.LogFrame (logger Logger , frame wire .Frame , sent bool )
func github.com/quic-go/quic-go/internal/wire.LogShortHeader (logger Logger , dest protocol .ConnectionID , pn protocol .PacketNumber , pnLen protocol .PacketNumberLen , kp protocol .KeyPhaseBit )
func github.com/quic-go/quic-go/internal/wire.(*ExtendedHeader ).Log (logger Logger )
As Types Of (only one )
var DefaultLogger
type RTTStats (struct)
RTTStats provides round-trip statistics
Methods (total 12 )
(*RTTStats) Clone () *RTTStats
(*RTTStats) HasMeasurement () bool
(*RTTStats) LatestRTT () time .Duration
LatestRTT returns the most recent rtt measurement.
May return Zero if no valid updates have occurred.
(*RTTStats) MaxAckDelay () time .Duration
MaxAckDelay gets the max_ack_delay advertised by the peer
(*RTTStats) MeanDeviation () time .Duration
MeanDeviation gets the mean deviation
(*RTTStats) MinRTT () time .Duration
MinRTT Returns the minRTT for the entire connection.
May return Zero if no valid updates have occurred.
(*RTTStats) PTO (includeMaxAckDelay bool ) time .Duration
PTO gets the probe timeout duration.
(*RTTStats) ResetForPathMigration ()
(*RTTStats) SetInitialRTT (t time .Duration )
SetInitialRTT sets the initial RTT.
It is used during handshake when restoring the RTT stats from the token.
(*RTTStats) SetMaxAckDelay (mad time .Duration )
SetMaxAckDelay sets the max_ack_delay
(*RTTStats) SmoothedRTT () time .Duration
SmoothedRTT returns the smoothed RTT for the connection.
May return Zero if no valid updates have occurred.
(*RTTStats) UpdateRTT (sendDelta, ackDelay time .Duration )
UpdateRTT updates the RTT based on a new sample.
As Outputs Of (at least 2 )
func NewRTTStats () *RTTStats
func (*RTTStats).Clone () *RTTStats
As Inputs Of (at least 6 )
func github.com/quic-go/quic-go/internal/ackhandler.NewSentPacketHandler (initialPN protocol .PacketNumber , initialMaxDatagramSize protocol .ByteCount , rttStats *RTTStats , connStats *ConnectionStats , clientAddressValidated bool , enableECN bool , ignorePacketsBelow func(protocol .PacketNumber ), pers protocol .Perspective , qlogger qlogwriter .Recorder , logger Logger ) ackhandler .SentPacketHandler
func github.com/quic-go/quic-go/internal/congestion.NewCubicSender (clock congestion .Clock , rttStats *RTTStats , connStats *ConnectionStats , initialMaxDatagramSize protocol .ByteCount , reno bool , qlogger qlogwriter .Recorder ) *congestion .cubicSender
func github.com/quic-go/quic-go/internal/flowcontrol.NewConnectionFlowController (receiveWindow protocol .ByteCount , maxReceiveWindow protocol .ByteCount , allowWindowIncrease func(size protocol .ByteCount ) bool , rttStats *RTTStats , logger Logger ) *flowcontrol .connectionFlowController
func github.com/quic-go/quic-go/internal/flowcontrol.NewStreamFlowController (streamID protocol .StreamID , cfc flowcontrol .ConnectionFlowController , receiveWindow protocol .ByteCount , maxReceiveWindow protocol .ByteCount , initialSendWindow protocol .ByteCount , rttStats *RTTStats , logger Logger ) flowcontrol .StreamFlowController
func github.com/quic-go/quic-go/internal/handshake.NewCryptoSetupClient (connID protocol .ConnectionID , tp *wire .TransportParameters , tlsConf *tls .Config , enable0RTT bool , rttStats *RTTStats , qlogger qlogwriter .Recorder , logger Logger , version protocol .Version ) handshake .CryptoSetup
func github.com/quic-go/quic-go/internal/handshake.NewCryptoSetupServer (connID protocol .ConnectionID , localAddr, remoteAddr net .Addr , tp *wire .TransportParameters , tlsConf *tls .Config , allow0RTT bool , rttStats *RTTStats , qlogger qlogwriter .Recorder , logger Logger , version protocol .Version ) handshake .CryptoSetup
Package-Level Functions (total 2)
Package-Level Variables (only one)
Package-Level Constants (total 5)
The pages are generated with Golds v0.8.2 . (GOOS=linux GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu .
PR and bug reports are welcome and can be submitted to the issue list .
Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds .