Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewHandler ¶
func NewHandler(opts ...HandlerOption) emperror.Handler
NewHandler returns a new error handler.
Types ¶
type HandlerOption ¶
type HandlerOption func(o *options)
HandlerOption sets options in the error handler.
func Conditional ¶ added in v0.2.0
func Conditional(c bool, op HandlerOption) HandlerOption
Conditional applies an option if the condition is true. This is useful to avoid using conditional logic when building the option list.
func Handler ¶ added in v0.2.0
func Handler(h emperror.Handler) HandlerOption
Handler appends a handler to the handler stack.
Click to show internal directories.
Click to hide internal directories.