Versions in this module Expand all Collapse all v1 v1.0.1 Nov 3, 2017 Changes in this version + const MARKDOWN v1.0.0 Oct 31, 2017 Changes in this version + const HTML + const LOCALE + const PRODUCTION + const TEXT + var AuthorEmail string + var AuthorName string + var BuildTime string + var Copyright string + var Usage string + var Version string + func ConfigAction(f cli.ActionFunc) cli.ActionFunc + func FuncName(f interface{}) string + func InjectAction(f cli.ActionFunc) cli.ActionFunc + func LoggerMiddleware(wrt http.ResponseWriter, req *http.Request, next http.HandlerFunc) + func MODE() string + func Main(args ...string) error + func RandomBytes(l int) ([]byte, error) + func Register(args ...Plugin) + func SECRET() ([]byte, error) + func Shell(cmd string, args ...string) error + type Cache struct + func NewCache(pool *redis.Pool, prefix string) *Cache + func (p *Cache) Flush() error + func (p *Cache) Get(key string, val interface{}) error + func (p *Cache) Keys() ([]string, error) + func (p *Cache) Set(key string, val interface{}, ttl time.Duration) error + type Consumer func(id string, body []byte) error + type I18n struct + func NewI18n(path string, db *pg.DB) (*I18n, error) + func (p *I18n) E(lang, code string, args ...interface{}) error + func (p *I18n) H(lang, code string, obj interface{}) (string, error) + func (p *I18n) Languages() ([]string, error) + func (p *I18n) Middleware(tags ...language.Tag) gin.HandlerFunc + func (p *I18n) Set(tx *pg.Tx, lang, code, message string) error + func (p *I18n) T(lang, code string, args ...interface{}) string + type Jobber struct + func NewJobber(url, queue string) (*Jobber, error) + func (p *Jobber) Receive(consumer string) error + func (p *Jobber) Register(_type string, hnd Consumer) + func (p *Jobber) Send(_type string, priority uint8, body interface{}) error + func (p *Jobber) Status() map[string]interface{} + type Jwt struct + func NewJwt(key []byte, method crypto.SigningMethod) *Jwt + func (p *Jwt) Parse(r *http.Request) (jwt.Claims, error) + func (p *Jwt) Sum(cm jws.Claims, exp time.Duration) ([]byte, error) + func (p *Jwt) Validate(buf []byte) (jwt.Claims, error) + type Locale struct + Code string + CreatedAt time.Time + ID uint + Lang string + Message string + UpdatedAt time.Time + type Plugin interface + Init func(*inject.Graph) error + Mount func() error + Shell func() []cli.Command + type S3 struct + func NewS3(accessKeyID, secretAccessKey, region, bucket string) (*S3, error) + func (p *S3) Write(name string, body []byte, size int64) (string, string, error) + type Security struct + func NewSecurity(key []byte) (*Security, error) + func (p *Security) Check(encode, plain []byte) bool + func (p *Security) Decrypt(buf []byte) ([]byte, error) + func (p *Security) Encrypt(buf []byte) ([]byte, error) + func (p *Security) Hash(plain []byte) ([]byte, error) + type Setting struct + CreatedAt time.Time + Encode bool + ID uint + Key string + UpdatedAt time.Time + Value []byte + type Settings struct + func NewSettings(db *pg.DB, sec *Security) *Settings + func (p *Settings) Get(key string, obj interface{}) error + func (p *Settings) Set(tx *pg.Tx, key string, obj interface{}, encode bool) error + type UEditor struct + func (p *UEditor) Upload(wrt UEditorWriter, images UEditorManager, files UEditorManager) gin.HandlerFunc + type UEditorManager func(c *gin.Context) (urls []string, err error) + type UEditorWriter func(c *gin.Context, name string, buf []byte, size int64) (url string, err error)