func (e *ErrorAssistant) Stack(err interface{}) string {
	return e.p().StackError(err)
}
Stack acquires an error full stack info string
package gmc
import (
	"fmt"
	"github.com/snail007/gmc/core"
	"github.com/snail007/gmc/module/cache"
	gdb "github.com/snail007/gmc/module/db"
	gi18n "github.com/snail007/gmc/module/i18n"
	gcaptcha "github.com/snail007/gmc/util/captcha"
	gmap "github.com/snail007/gmc/util/map"
)
var (
	New = &NewAssistant{}
	DB = &DBAssistant{}
	Cache = &CacheAssistant{}
	I18n = &I18nAssistant{}
	Err = &ErrorAssistant{}
)
type NewAssistant struct {
}
func (s *NewAssistant) Config() gcore.Config {
	return gcore.ProviderConfig()()
}
func (s *NewAssistant) ConfigFile(file string) (cfg gcore.Config, err error) {
	v := s.Config()
	v.SetConfigFile(file)
	err = v.ReadInConfig()
	if err != nil {
		return
	}
	cfg = v
	return
}
func (s *NewAssistant) Ctx() gcore.Ctx {
	return gcore.ProviderCtx()()
}
func (s *NewAssistant) Logger(ctx gcore.Ctx, prefix string) gcore.Logger {
	return gcore.ProviderLogger()(ctx, prefix)
}
func (s *NewAssistant) App() gcore.App {
	return gcore.ProviderApp()(false)
}
func (s *NewAssistant) Captcha() *gcaptcha.Captcha {
	return gcaptcha.New()
}
func (s *NewAssistant) CaptchaDefault() *gcaptcha.Captcha {
	return gcaptcha.NewDefault()
}
func (s *NewAssistant) Tr(lang string, ctx gcore.Ctx) (tr gcore.I18n) {
	tr, _ = gcore.ProviderI18n()(ctx)
	tr.Lang(lang)
	return
}
func (s *NewAssistant) AppDefault() gcore.App {
	return gcore.ProviderApp()(true)
}
func (s *NewAssistant) Router(ctx gcore.Ctx) gcore.HTTPRouter {
	return gcore.ProviderHTTPRouter()(ctx)
}
func (s *NewAssistant) HTTPServer(ctx gcore.Ctx) gcore.HTTPServer {
	return gcore.ProviderHTTPServer()(ctx)
}
func (s *NewAssistant) APIServer(ctx gcore.Ctx, address string) (gcore.APIServer, error) {
	return gcore.ProviderAPIServer()(ctx, address)
}
func (s *NewAssistant) APIServerDefault(ctx gcore.Ctx) (gcore.APIServer, error) {
	return gcore.ProviderAPIServer()(ctx, "")
}
func (s *NewAssistant) Map() *gmap.Map {
	return gmap.New()
}
type DBAssistant struct {
}
func (s *DBAssistant) Init(cfg gcore.Config) error {
	return gdb.Init(cfg)
}
func (s *DBAssistant) InitFromFile(cfgFile string) error {
	return gdb.InitFromFile(cfgFile)
}
func (s *DBAssistant) DB(id ...string) gcore.Database {
	return gdb.DB(id...)
}
func (s *DBAssistant) MySQL(id ...string) *gdb.MySQLDB {
	return gdb.DBMySQL(id...)
}
func (s *DBAssistant) SQLite3(id ...string) *gdb.SQLite3DB {
	return gdb.DBSQLite3(id...)
}
func (s *DBAssistant) Table(tableName string) *gdb.Model {
	return gdb.Table(tableName)
}
type CacheAssistant struct {
}
func (s *CacheAssistant) Init(cfg gcore.Config) error {
	return gcache.Init(cfg)
}
func (s *CacheAssistant) Cache(id ...string) gcore.Cache {
	return gcache.Cache(id...)
}
func (s *CacheAssistant) Redis(id ...string) *gcache.RedisCache {
	return gcache.Redis(id...)
}
func (s *CacheAssistant) File(id ...string) *gcache.FileCache {
	return gcache.File(id...)
}
func (s *CacheAssistant) Memory(id ...string) *gcache.MemCache {
	return gcache.Memory(id...)
}
type I18nAssistant struct {
}
func (s *I18nAssistant) Init(cfg gcore.Config) (i18n gcore.I18n, err error) {
	err = gi18n.Init(cfg)
	if err != nil {
		return
	}
	i18n = gi18n.I18N
	return
}
type ErrorAssistant struct {
	p gcore.ErrorProvider
}
func NewErrorAssistant() *ErrorAssistant {
	return &ErrorAssistant{p: gcore.ProviderError()}
}