Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HandlerError ¶
Types ¶
type StatusError ¶
func Format ¶
func Format(format string, args ...any) *StatusError
func From ¶
func From(err error) *StatusError
func New ¶
func New(msg string) *StatusError
func (*StatusError) Error ¶
func (c *StatusError) Error() string
func (*StatusError) SetError ¶
func (c *StatusError) SetError(err error) *StatusError
func (*StatusError) SetMessage ¶
func (c *StatusError) SetMessage(msg string) *StatusError
func (*StatusError) SetStatus ¶
func (c *StatusError) SetStatus(status int) *StatusError
SetStatus 自定义的状态码应当大于1000
func (*StatusError) String ¶
func (c *StatusError) String() string
Click to show internal directories.
Click to hide internal directories.