Documentation ¶
Overview ¶
Package quicstream supports stream, based on quic.
Index ¶
- func IsNetworkError(err error) bool
- func WritePrefix(w io.Writer, prefix string) error
- type Client
- type ClientWriteFunc
- type DialFunc
- type ErrorHandler
- type Handler
- type PoolClient
- func (p *PoolClient) Add(addr *net.UDPAddr, client *Client) bool
- func (p *PoolClient) Clean(cleanDuration time.Duration) int
- func (p *PoolClient) Client(addr *net.UDPAddr) (*Client, bool)
- func (p *PoolClient) Close() error
- func (p *PoolClient) Dial(ctx context.Context, addr *net.UDPAddr, newClient func(*net.UDPAddr) *Client) (quic.EarlyConnection, error)
- func (p *PoolClient) Remove(addr *net.UDPAddr) bool
- func (p *PoolClient) Write(ctx context.Context, addr *net.UDPAddr, f func(io.Writer) error, ...) (quic.Stream, error)
- type PrefixHandler
- type Server
- type UDPConnInfo
- func (c UDPConnInfo) Addr() net.Addr
- func (c UDPConnInfo) IsValid([]byte) error
- func (c UDPConnInfo) MarshalText() ([]byte, error)
- func (c UDPConnInfo) String() string
- func (c UDPConnInfo) TLSInsecure() bool
- func (c UDPConnInfo) UDPAddr() *net.UDPAddr
- func (c *UDPConnInfo) UnmarshalText(b []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsNetworkError ¶
Types ¶
type ClientWriteFunc ¶
func DefaultClientWriteFunc ¶
func DefaultClientWriteFunc(b []byte) ClientWriteFunc
type PoolClient ¶
type PoolClient struct {
// contains filtered or unexported fields
}
func NewPoolClient ¶
func NewPoolClient() *PoolClient
func (*PoolClient) Close ¶
func (p *PoolClient) Close() error
type PrefixHandler ¶
type PrefixHandler struct {
// contains filtered or unexported fields
}
func NewPrefixHandler ¶
func NewPrefixHandler(errorHandler ErrorHandler) *PrefixHandler
func (*PrefixHandler) Add ¶
func (h *PrefixHandler) Add(prefix string, handler Handler) *PrefixHandler
type Server ¶
type Server struct { *logging.Logging *util.ContextDaemon // contains filtered or unexported fields }
type UDPConnInfo ¶
type UDPConnInfo struct {
// contains filtered or unexported fields
}
func MustNewUDPConnInfoFromString ¶
func MustNewUDPConnInfoFromString(s string) UDPConnInfo
func NewUDPConnInfo ¶
func NewUDPConnInfo(addr *net.UDPAddr, tlsinsecure bool) UDPConnInfo
func NewUDPConnInfoFromString ¶
func NewUDPConnInfoFromString(s string) (UDPConnInfo, error)
func NewUDPConnInfoFromStringAddress ¶
func NewUDPConnInfoFromStringAddress(s string, tlsinsecure bool) (ci UDPConnInfo, _ error)
func (UDPConnInfo) Addr ¶
func (c UDPConnInfo) Addr() net.Addr
func (UDPConnInfo) IsValid ¶
func (c UDPConnInfo) IsValid([]byte) error
func (UDPConnInfo) MarshalText ¶
func (c UDPConnInfo) MarshalText() ([]byte, error)
func (UDPConnInfo) String ¶
func (c UDPConnInfo) String() string
func (UDPConnInfo) TLSInsecure ¶
func (c UDPConnInfo) TLSInsecure() bool
func (UDPConnInfo) UDPAddr ¶
func (c UDPConnInfo) UDPAddr() *net.UDPAddr
func (*UDPConnInfo) UnmarshalText ¶
func (c *UDPConnInfo) UnmarshalText(b []byte) error
Click to show internal directories.
Click to hide internal directories.