Documentation ¶
Index ¶
- Variables
- func NewCache(maxBytes int64) *cache
- func RandomString(n int) string
- func Register(f ICtrl, prefix string)
- func SetCookieConfig(c *CookieConfig)
- func SetSessionConfig(s *SessionConfig)
- func SizeStruct(data interface{}) int64
- func Start(addr string)
- type BaseCtrl
- type Context
- type CookieConfig
- type DefHandler
- type EleMapValue
- type ICache
- type ICtrl
- type ISession
- type Session
- type SessionConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var Router = router{ // contains filtered or unexported fields }
Functions ¶
func RandomString ¶
func SetCookieConfig ¶
func SetCookieConfig(c *CookieConfig)
func SetSessionConfig ¶
func SetSessionConfig(s *SessionConfig)
func SizeStruct ¶
func SizeStruct(data interface{}) int64
Types ¶
type Context ¶
type CookieConfig ¶
type CookieConfig struct { SessionCookieName string Cache ICache Path string // optional Domain string // optional // MaxAge=0 means no 'Max-Age' attribute specified. // MaxAge<0 means delete cookie now, equivalently 'Max-Age: 0' // MaxAge>0 means Max-Age attribute present and given in seconds MaxAge int Secure bool HttpOnly bool }
type DefHandler ¶
type DefHandler struct { }
func (*DefHandler) ServeHTTP ¶
func (handler *DefHandler) ServeHTTP(resp http.ResponseWriter, req *http.Request)
type EleMapValue ¶
type EleMapValue struct {
// contains filtered or unexported fields
}
type Session ¶
type Session struct {
// contains filtered or unexported fields
}
func NewSession ¶
func (*Session) SetLastTime ¶
type SessionConfig ¶
Click to show internal directories.
Click to hide internal directories.