Documentation ¶
Index ¶
- func GinCors() gin.HandlerFunc
- func YamlLoad(config interface{}, file ...string) (err error)
- func ZapInit(options ...ZapOptions) (err error)
- type Aes
- type Cert
- type Const
- type ConstOptions
- type GinBind
- type Http
- type HttpHeader
- type Image
- type Jwt
- type JwtOptions
- type Logger
- type Mysql
- type MysqlOptions
- type Redis
- type RedisOptions
- type Snowflake
- type VerifyCode
- type YunFile
- type YunOSS
- type YunSMS
- type ZapOptions
- type Zlib
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Cert ¶
type Cert struct { Server credentials.TransportCredentials Client credentials.TransportCredentials }
证书实例
type ConstOptions ¶
type ConstOptions struct { ID int `json:"id,string"` Name string `json:"name"` Text string `json:"text"` }
常量配置
type HttpHeader ¶
type Jwt ¶
type Jwt struct {
// contains filtered or unexported fields
}
jwt实例
func (*Jwt) ParseToken ¶
解析凭证
type JwtOptions ¶
type JwtOptions struct { Issuer string //"" Passwd string //go-utils-jwt Expire int64 //7776000秒(90天) }
配置信息
type MysqlOptions ¶
type MysqlOptions struct { User string //"root" Port int32 //3306 MaxOpen int //100 MinIdle int //20 }
连接配置
type Redis ¶
type Redis struct { DB *redis.Client // contains filtered or unexported fields }
redis实例
type RedisOptions ¶
type RedisOptions struct { Prefix string //"" UserName string //"" Port int32 //6379 DB int //0 MaxOpen int //100 MinIdle int //20 LockTime int //5秒 }
连接配置
type YunOSS ¶
type YunOSS struct {
// contains filtered or unexported fields
}
存储实例
func NewYunOSS ¶
func NewYunOSS(accessKeyId, accessKeySecret, ossBucketName string, ossEndpoint ...string) (yun YunOSS, err error)
新建实例
type YunSMS ¶
type YunSMS struct {
// contains filtered or unexported fields
}
短信实例
Click to show internal directories.
Click to hide internal directories.