Documentation
¶
Index ¶
- func Run(ctx context.Context, port uint16, handler http.Handler, opts ...Opt) error
- type Opt
- func WithAddress(host string, port uint16) Opt
- func WithHandler(handler http.Handler) Opt
- func WithIdleTimeout(d time.Duration) Opt
- func WithMaxHeaderBytes(i int) Opt
- func WithReadHeaderTimeout(d time.Duration) Opt
- func WithReadTimeout(d time.Duration) Opt
- func WithShutdownTimeout(d time.Duration) Opt
- func WithTLSConfig(conf *tls.Config) Opt
- func WithWriteTimeout(d time.Duration) Opt
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Opt ¶ added in v2.1.0
type Opt func(*Server)
func WithAddress ¶
func WithHandler ¶
func WithIdleTimeout ¶
func WithMaxHeaderBytes ¶
func WithReadHeaderTimeout ¶
func WithReadTimeout ¶
func WithShutdownTimeout ¶
func WithTLSConfig ¶
func WithWriteTimeout ¶
Click to show internal directories.
Click to hide internal directories.