Documentation ¶
Index ¶
- func Debug(ctx Context, v ...interface{})
- func Debugf(ctx Context, f string, v ...interface{})
- func DoneWithStatus(c *gin.Context, result interface{})
- func Error(ctx Context, v ...interface{})
- func Errorf(ctx Context, f string, v ...interface{})
- func FromCodeErrorWithStatus(c *gin.Context, err CodeError)
- func GetAppName() (result string)
- func Info(ctx Context, v ...interface{})
- func Infof(ctx Context, f string, v ...interface{})
- func Panic(ctx Context, v ...interface{})
- func Panicf(ctx Context, f string, v ...interface{})
- func Trace(ctx Context, v ...interface{})
- func Tracef(ctx Context, f string, v ...interface{})
- func Warn(ctx Context, v ...interface{})
- func Warnf(ctx Context, f string, v ...interface{})
- type CarrierCodeError
- type CodeError
- type Context
- func (ctx *Context) CopyContext() (result Context)
- func (ctx *Context) Deadline() (deadline time.Time, ok bool)
- func (ctx *Context) Done() (done <-chan struct{})
- func (ctx *Context) Err() (err error)
- func (ctx *Context) Get(key string) (result interface{}, ok bool)
- func (ctx *Context) GetAllMap() (result map[string]interface{})
- func (ctx *Context) GetBool(key string) (result bool, ok bool)
- func (ctx *Context) GetDuration(key string) (result time.Duration, ok bool)
- func (ctx *Context) GetFloat64(key string) (result float64, ok bool)
- func (ctx *Context) GetInt(key string) (result int, ok bool)
- func (ctx *Context) GetIntSlice(key string) (result []int, ok bool)
- func (ctx *Context) GetString(key string) (result string, ok bool)
- func (ctx *Context) GetStringMap(key string) (result map[string]interface{}, ok bool)
- func (ctx *Context) GetStringMapString(key string) (result map[string]string, ok bool)
- func (ctx *Context) GetStringSlice(key string) (result []string, ok bool)
- func (ctx *Context) GetTime(key string) (result time.Time, ok bool)
- func (ctx *Context) IsSet(key string) (ok bool)
- func (ctx *Context) Set(key string, value interface{})
- func (ctx *Context) SetCancel() (cancelFunc context.CancelFunc)
- func (ctx *Context) SetDeadline(deadline time.Time) (ok bool, cancelFunc context.CancelFunc)
- func (ctx *Context) SetTimeout(timeout time.Duration) (cancelFunc context.CancelFunc)
- func (ctx *Context) Value(key interface{}) (result interface{})
- func (ctx *Context) WithCancel() (result Context, cancelFunc context.CancelFunc)
- func (ctx *Context) WithDeadline(deadline time.Time) (ok bool, result Context, cancelFunc context.CancelFunc)
- func (ctx *Context) WithTimeout(timeout time.Duration) (result Context, cancelFunc context.CancelFunc)
- type Version
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DoneWithStatus ¶
func FromCodeErrorWithStatus ¶
func GetAppName ¶
func GetAppName() (result string)
Types ¶
type CarrierCodeError ¶
type CarrierCodeError struct {
// contains filtered or unexported fields
}
func FromNativeError ¶
func FromNativeError(err error) (result CarrierCodeError)
func NewCarrierCodeError ¶
func NewCarrierCodeError(ec, sec int, em string) (result CarrierCodeError)
func (CarrierCodeError) Error ¶
func (err CarrierCodeError) Error() (msg string)
func (CarrierCodeError) ErrorCode ¶
func (err CarrierCodeError) ErrorCode() (ec int)
func (CarrierCodeError) ErrorMessage ¶
func (err CarrierCodeError) ErrorMessage() (em string)
func (CarrierCodeError) FullError ¶
func (err CarrierCodeError) FullError() (msg string)
func (CarrierCodeError) SubErrorCode ¶
func (err CarrierCodeError) SubErrorCode() (sec int)
type Context ¶
type Context struct {
// contains filtered or unexported fields
}
func NewContext ¶
func NewContext() (ctx Context)
func (*Context) CopyContext ¶
func (*Context) GetDuration ¶
func (*Context) GetStringMap ¶
func (*Context) GetStringMapString ¶
func (*Context) GetStringSlice ¶
func (*Context) SetCancel ¶
func (ctx *Context) SetCancel() (cancelFunc context.CancelFunc)
func (*Context) SetDeadline ¶
func (*Context) SetTimeout ¶
func (ctx *Context) SetTimeout(timeout time.Duration) (cancelFunc context.CancelFunc)
func (*Context) WithCancel ¶
func (ctx *Context) WithCancel() (result Context, cancelFunc context.CancelFunc)
func (*Context) WithDeadline ¶
func (*Context) WithTimeout ¶
type Version ¶
type Version struct { AppName string `json:"app_name"` AppVersion string `json:"app_version"` GitBranch string `json:"git_branch"` GitCommit string `json:"git_commit"` BuildDate string `json:"build_date"` GoOS string `json:"go_os"` GoArch string `json:"go_arch"` GoVer string `json:"go_ver"` }
func GetVersion ¶
func GetVersion() (result Version)
Click to show internal directories.
Click to hide internal directories.