Documentation ¶
Index ¶
- Constants
- type ApiGorm
- func (ag *ApiGorm) GormDeleteData(ctx context.Context, hour int64) error
- func (ag *ApiGorm) GormDeleteDataCustom(ctx context.Context, tableName string, hour int64) error
- func (ag *ApiGorm) Middleware(ctx context.Context, request gorequest.Response)
- func (ag *ApiGorm) MiddlewareCustom(ctx context.Context, api string, request gorequest.Response)
- func (ag *ApiGorm) MiddlewareXml(ctx context.Context, request gorequest.Response)
- type ApiGormFun
- type ApiSLog
- func (al *ApiSLog) ConfigSLogClientFun(sLogFun SLogFun)
- func (al *ApiSLog) ConfigSLogResultClientFun(sLogFun SLogFun) *ApiSLog
- func (al *ApiSLog) Middleware(ctx context.Context, request gorequest.Response)
- func (al *ApiSLog) MiddlewareCustom(ctx context.Context, api string, request gorequest.Response)
- func (al *ApiSLog) MiddlewareXml(ctx context.Context, request gorequest.Response)
- type ApiSLogFun
- type ContextHandler
- type GinCustomClientGinRecordOperation
- type GinGorm
- type GinGormFun
- type GinSLog
- type GinSLogCustom
- type GinSLogCustomFun
- type GinSLogFun
- type HertzGorm
- type HertzGormFun
- type SLog
- type SLogFun
- type SLogOption
Constants ¶
const (
Version = "1.0.129"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApiGorm ¶ added in v1.0.103
type ApiGorm struct {
// contains filtered or unexported fields
}
ApiGorm 接口日志
func NewApiGorm ¶ added in v1.0.103
NewApiGorm 创建接口实例化
func (*ApiGorm) GormDeleteData ¶ added in v1.0.108
GormDeleteData 删除N小时前数据
func (*ApiGorm) GormDeleteDataCustom ¶ added in v1.0.108
GormDeleteDataCustom 删除N小时前数据
func (*ApiGorm) Middleware ¶ added in v1.0.103
Middleware 中间件
func (*ApiGorm) MiddlewareCustom ¶ added in v1.0.103
MiddlewareCustom 中间件
type ApiSLog ¶ added in v1.0.103
type ApiSLog struct {
// contains filtered or unexported fields
}
ApiSLog 接口日志
func NewApiSlog ¶ added in v1.0.103
func (*ApiSLog) ConfigSLogClientFun ¶ added in v1.0.103
ConfigSLogClientFun 日志配置
func (*ApiSLog) ConfigSLogResultClientFun ¶ added in v1.0.103
ConfigSLogResultClientFun 日志配置然后返回
func (*ApiSLog) Middleware ¶ added in v1.0.103
Middleware 中间件
func (*ApiSLog) MiddlewareCustom ¶ added in v1.0.103
MiddlewareCustom 中间件
type ContextHandler ¶ added in v1.0.129
type GinCustomClientGinRecordOperation ¶ added in v1.0.103
type GinCustomClientGinRecordOperation struct {
// contains filtered or unexported fields
}
func (*GinCustomClientGinRecordOperation) CreateData ¶ added in v1.0.103
func (o *GinCustomClientGinRecordOperation) CreateData()
func (*GinCustomClientGinRecordOperation) CreateDataNoError ¶ added in v1.0.103
func (o *GinCustomClientGinRecordOperation) CreateDataNoError()
func (*GinCustomClientGinRecordOperation) CustomInfo ¶ added in v1.0.103
func (o *GinCustomClientGinRecordOperation) CustomInfo(customId any, customType any, customContent any) *GinCustomClientGinRecordOperation
type GinGorm ¶ added in v1.0.105
type GinGorm struct {
// contains filtered or unexported fields
}
GinGorm 框架日志
func NewGinGorm ¶ added in v1.0.105
NewGinGorm 创建框架实例化
func (*GinGorm) GormDeleteData ¶ added in v1.0.108
GormDeleteData 删除N小时前数据
func (*GinGorm) GormDeleteDataCustom ¶ added in v1.0.108
GormDeleteDataCustom 删除N小时前数据
func (*GinGorm) Middleware ¶ added in v1.0.105
func (gg *GinGorm) Middleware() gin.HandlerFunc
Middleware 中间件
type GinSLog ¶ added in v1.0.105
type GinSLog struct {
// contains filtered or unexported fields
}
GinSLog 框架日志
func NewGinSLog ¶ added in v1.0.105
NewGinSLog 创建框架实例化
func (*GinSLog) ConfigSLogClientFun ¶ added in v1.0.105
ConfigSLogClientFun 日志配置
func (*GinSLog) ConfigSLogResultClientFun ¶ added in v1.0.105
ConfigSLogResultClientFun 日志配置然后返回
func (*GinSLog) Middleware ¶ added in v1.0.105
func (gl *GinSLog) Middleware() gin.HandlerFunc
Middleware 中间件
type GinSLogCustom ¶ added in v1.0.105
type GinSLogCustom struct {
// contains filtered or unexported fields
}
GinSLogCustom 框架自定义日志
func NewGinSLogCustom ¶ added in v1.0.105
func NewGinSLogCustom(ctx context.Context) (*GinSLogCustom, error)
NewGinSLogCustom 创建框架实例化
func (*GinSLogCustom) ConfigSLogClientFun ¶ added in v1.0.105
func (c *GinSLogCustom) ConfigSLogClientFun(sLogFun SLogFun)
ConfigSLogClientFun 日志配置
func (*GinSLogCustom) ConfigSLogResultClientFun ¶ added in v1.0.105
func (c *GinSLogCustom) ConfigSLogResultClientFun(sLogFun SLogFun) *GinSLogCustom
ConfigSLogResultClientFun 日志配置然后返回
func (*GinSLogCustom) GinRecord ¶ added in v1.0.105
func (c *GinSLogCustom) GinRecord(ginCtx *gin.Context) *GinCustomClientGinRecordOperation
GinRecord 记录日志
type GinSLogCustomFun ¶ added in v1.0.105
type GinSLogCustomFun func() *GinSLogCustom
GinSLogCustomFun 框架自定义日志驱动
type HertzGorm ¶ added in v1.0.122
type HertzGorm struct {
// contains filtered or unexported fields
}
HertzGorm 框架日志
func NewHertzGorm ¶ added in v1.0.122
func NewHertzGorm(ctx context.Context, gormClient *gorm.DB, gormTableName string) (*HertzGorm, error)
NewHertzGorm 创建框架实例化
func (*HertzGorm) GormDeleteData ¶ added in v1.0.125
GormDeleteData 删除N小时前数据
func (*HertzGorm) GormDeleteDataCustom ¶ added in v1.0.125
GormDeleteDataCustom 删除N小时前数据
func (*HertzGorm) Middleware ¶ added in v1.0.122
func (hg *HertzGorm) Middleware() app.HandlerFunc
Middleware 中间件
type HertzGormFun ¶ added in v1.0.122
type HertzGormFun func() *HertzGorm
HertzGormFun *HertzGorm 框架日志驱动
type SLog ¶ added in v1.0.103
type SLog struct {
// contains filtered or unexported fields
}
func (*SLog) WithLogger ¶ added in v1.0.103
WithLogger 跟踪编号
func (*SLog) WithTraceID ¶ added in v1.0.115
WithTraceID 跟踪编号
func (*SLog) WithTraceIDStr ¶ added in v1.0.115
WithTraceIDStr 跟踪编号
func (*SLog) WithTraceId ¶ added in v1.0.103
WithTraceId 跟踪编号
type SLogOption ¶ added in v1.0.128
type SLogOption func(*SLog)
func WithSLogLumberjack ¶ added in v1.0.128
func WithSLogLumberjack(config lumberjack.Logger) SLogOption
WithSLogLumberjack Lumberjack配置 Filename 日志文件的位置 MaxSize 文件最大尺寸(以MB为单位) MaxAge 留旧文件的最大天数 MaxBackups 保留的最大旧文件数量 Compress 是否压缩/归档旧文件 LocalTime 使用本地时间创建时间戳
func WithSLogSetDefault ¶ added in v1.0.129
func WithSLogSetDefault() SLogOption
WithSLogSetDefault 设置为默认的实例
func WithSLogSetDefaultCtx ¶ added in v1.0.129
func WithSLogSetDefaultCtx() SLogOption
WithSLogSetDefaultCtx 设置默认上下文
Source Files ¶
- api_gorm.go
- api_gorm_config.go
- api_gorm_delete.go
- api_gorm_model.go
- api_gorm_record.go
- api_slog.go
- api_slog_config.go
- api_slog_model.go
- api_slog_record.go
- config.go
- gin_gorm.go
- gin_gorm_config.go
- gin_gorm_delete.go
- gin_gorm_model.go
- gin_gorm_record.go
- gin_slog.go
- gin_slog_cofing.go
- gin_slog_custom.go
- gin_slog_custom_config.go
- gin_slog_custom_model.go
- gin_slog_custom_record.go
- gin_slog_model.go
- gin_slog_record.go
- hertz_gorm.go
- hertz_gorm_config.go
- hertz_gorm_delete.go
- hertz_gorm_model.go
- hertz_gorm_record.go
- slog.go
- slog_handler.go
- slog_option.go
- version.go