Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApplicationError ¶
type ApplicationError interface { //TODO Should we embed log.Error in here and add a new function New(err errors, code, message string) *ApplicationError Error() string String() string ErrorCode() string ErrorMessage() string }
ApplicationError is an interface to all application errors It provides functions to get the error code and error message
type BaseApplicationError ¶
BaseApplicationError implements the `ApplicationError`
func (*BaseApplicationError) Error ¶
func (e *BaseApplicationError) Error() string
Error returns string representation of error
func (*BaseApplicationError) ErrorCode ¶
func (e *BaseApplicationError) ErrorCode() string
ErrorCode returns the unique code of the error
func (*BaseApplicationError) ErrorMessage ¶
func (e *BaseApplicationError) ErrorMessage() string
ErrorMessage returns the readable message of the error
func (*BaseApplicationError) String ¶
func (e *BaseApplicationError) String() string
String implementation supports logging
Click to show internal directories.
Click to hide internal directories.