Documentation ¶
Index ¶
- func DialContextFunc(dial func(context.Context, string, string) (net.Conn, error)) func(context.Context, string, string) (net.Conn, error)
- func DialContextFuncWith(logger *events.Logger, ...) func(context.Context, string, string) (net.Conn, error)
- func DialFunc(dial func(string, string) (net.Conn, error)) func(string, string) (net.Conn, error)
- func DialFuncWith(logger *events.Logger, dial func(string, string) (net.Conn, error)) func(string, string) (net.Conn, error)
- func NewHandler(handler netx.Handler) netx.Handler
- func NewHandlerWith(logger *events.Logger, handler netx.Handler) netx.Handler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DialContextFunc ¶
func DialContextFunc(dial func(context.Context, string, string) (net.Conn, error)) func(context.Context, string, string) (net.Conn, error)
DialContextFuncWith returns a wrapper for dial which logs with the default logger all opening and closing events that occur on the connections returned by the dial function.
func DialContextFuncWith ¶
func DialContextFuncWith(logger *events.Logger, dial func(context.Context, string, string) (net.Conn, error)) func(context.Context, string, string) (net.Conn, error)
DialContextFuncWith returns a wrapper for dial which logs with logger all opening and closing events that occur on the connections returned by the dial function.
func DialFunc ¶
DialFunc returns a wrapper for dial which logs with the default logger all opening and closing events that occur on the connections returned by the dial function.
func DialFuncWith ¶
func DialFuncWith(logger *events.Logger, dial func(string, string) (net.Conn, error)) func(string, string) (net.Conn, error)
DialFuncWith returns a wrapper for dial which logs with logger all opening and closing events that occur on the connections returned by the dial function.
func NewHandler ¶
NewHandler returns a wrapper for handler which logs with the default logger all opening and closing events that occur on the connections servied by the handler.
Types ¶
This section is empty.