Documentation
¶
Index ¶
- type Error
- type ErrorObject
- func (e ErrorObject) AddParam(name string, value interface{}) Error
- func (e ErrorObject) Code() string
- func (e ErrorObject) Error() string
- func (e ErrorObject) Message() string
- func (e ErrorObject) Params() map[string]interface{}
- func (e ErrorObject) SetCode(code string) Error
- func (e ErrorObject) SetMessage(message string) Error
- func (e ErrorObject) SetParams(params map[string]interface{}) Error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Error ¶
type Error interface { Error() string Code() string Message() string SetMessage(string) Error Params() map[string]interface{} SetParams(map[string]interface{}) Error }
Error interface represents an validation error
type ErrorObject ¶
type ErrorObject struct {
// contains filtered or unexported fields
}
func (ErrorObject) AddParam ¶
func (e ErrorObject) AddParam(name string, value interface{}) Error
AddParam add parameter to the error's parameters.
func (ErrorObject) Message ¶
func (e ErrorObject) Message() string
Message return the error's message.
func (ErrorObject) Params ¶
func (e ErrorObject) Params() map[string]interface{}
Params returns the error's params.
func (ErrorObject) SetCode ¶
func (e ErrorObject) SetCode(code string) Error
SetCode set the error's translation code.
func (ErrorObject) SetMessage ¶
func (e ErrorObject) SetMessage(message string) Error
SetMessage set the error's message.
func (ErrorObject) SetParams ¶
func (e ErrorObject) SetParams(params map[string]interface{}) Error
Click to show internal directories.
Click to hide internal directories.