Documentation ¶
Index ¶
Constants ¶
View Source
const ( ALL logLevel = iota DEBUG INFO WARN ERROR FATAL OFF )
View Source
const (
//TimeLayout define a time format
TimeLayout = "2006-01-02 15:04:05"
)
Variables ¶
View Source
var ( //LogFatal 崩溃日志记录器 LogFatal = lgFatal.Log //LogError 错误日志记录器 LogError = lgError.Log //LogWarn 警告日志记录器 LogWarn = lgWarn.Log //LogInfo 详情日志记录器 LogInfo = lgInfo.Log //LogDebug 测试日志记录器 LogDebug = lgDebug.Log )
View Source
var DB *xorm.Engine
DB 数据库引擎
Functions ¶
Types ¶
type CacheBucket ¶
func (*CacheBucket) SetWithExpireTime ¶
func (cb *CacheBucket) SetWithExpireTime(key string, obj kvcache.ObjectCacher, t time.Duration)
type DatabaseConfig ¶
type DatabaseConfig struct { DBAddress string `json:"db_address"` DBPort int `json:"db_port"` DBUser string `json:"db_user"` DBPassword string `json:"db_passwd"` DBName string `json:"db_name"` DBCharset string `json:"charset"` DBIdleConnectionNum int `json:"db_idle_connection_num"` DBMaxConnectionNum int `json:"db_max_connectiong_num"` }
DatabaseConfig 数据库配置
var ( //DatabaseCfg 运行时储存数据库相关配置 DatabaseCfg *DatabaseConfig )
func (*DatabaseConfig) String ¶
func (c *DatabaseConfig) String() string
type SiteConfig ¶
type SiteConfig struct { SiteName string `json:"site_name"` SiteDescription string `json:"site_description"` SiteKeyWords keywords `json:"site_keywords"` SiteOwner string `json:"site_owner"` SiteOwnerDescription string `json:"site_owner_description"` SiteOwnerWeibo string `json:"site_owner_weibo"` SiteOwnerWechat string `json:"site_owner_wechat"` SiteOwnerGithub string `json:"site_owner_github"` }
SiteConfig 网站配置
Source Files ¶
Click to show internal directories.
Click to hide internal directories.