Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IAccessLogFormat ¶ added in v0.1.9
type IComponentFunc ¶
type IContext ¶
type IContext interface { HttpRW(debug, enableAccessLog bool, r *http.Request, w http.ResponseWriter) Process(plugins []IPlugin) Notice(format string, v ...interface{}) Debug(format string, v ...interface{}) Info(format string, v ...interface{}) Warn(format string, v ...interface{}) Error(format string, v ...interface{}) Fatal(format string, v ...interface{}) FinishGoLog() Cache(name string, rv reflect.Value) Next() Abort() Copy() IContext ElapseMs() int LogId() string Status() int Size() int SetInput(r *http.Request) Input() *http.Request SetOutput(w http.ResponseWriter) Output() http.ResponseWriter SetControllerId(id string) ControllerId() string SetActionId(id string) ActionId() string SetUserData(key string, data interface{}) UserData(key string, dft interface{}) interface{} Method() string Query(name, dft string) string QueryAll() map[string]string Post(name, dft string) string PostAll() map[string]string Param(name, dft string) string ParamAll() map[string]string ParamMap(name string) map[string]string QueryMap(name string) map[string]string PostMap(name string) map[string]string ParamArray(name string) []string QueryArray(name string) []string PostArray(name string) []string Cookie(name, dft string) string CookieAll() map[string]string Header(name, dft string) string HeaderAll() map[string]string Path() string ClientIp() string ValidateQuery(name string, dft ...interface{}) *validate.String ValidatePost(name string, dft ...interface{}) *validate.String ValidateParam(name string, dft ...interface{}) *validate.String SetHeader(name, value string) SetCookie(cookie *http.Cookie) End(status int, data []byte) PushLog(key string, v interface{}) Counting(key string, hit, total int) ProfileStart(key string) ProfileStop(key string) ProfileAdd(key string, elapse time.Duration) PushLogString() string CountingString() string ProfileString() string SetAccessLogFormat(v IAccessLogFormat) SetEnableAccessLog(v bool) }
type IController ¶
type IErrorController ¶ added in v0.1.1
type IObjPoolFunc ¶
type IObjSingleFunc ¶
type IObjSingleFunc func(params ...interface{}) IObject
type IObject ¶
type IObject interface { SetContext(ctx IContext) Context() IContext GetObj(obj IObject) IObject GetObjPool(className string, funcName IObjPoolFunc, params ...interface{}) IObject GetObjBox(className string, params ...interface{}) IObject GetObjSingle(name string, funcName IObjSingleFunc, params ...interface{}) IObject GetObjPoolCtx(ctr IContext, className string, funcName IObjPoolFunc, params ...interface{}) IObject GetObjBoxCtx(ctx IContext, className string, params ...interface{}) IObject GetObjCtx(ctx IContext, obj IObject) IObject GetObjSingleCtx(ctx IContext, name string, funcName IObjSingleFunc, params ...interface{}) IObject }
Click to show internal directories.
Click to hide internal directories.