package
Version:
v0.0.0-...-88d673b
Opens a new window with list of versions in this module.
Published: Nov 18, 2021
License: Apache-2.0
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
func HTTPResponse(err error, body interface{}) (int, interface{})
HTTPResponse - this is used to set http response
type Error struct {
ErrorCode string `json:"errorCode"`
ErrorMessage string `json:"message"`
}
Error - this is the error response
AssignError - this will assign error
func New(errorCode string, logMessage ...interface{}) *Error
New - create new Error
Error - convert error into string
func (e Error) HTTPResponse(body interface{}) (int, interface{})
HTTPResponse - this is used to set http response
Source Files
¶
Click to show internal directories.
Click to hide internal directories.