Documentation ¶
Index ¶
- Constants
- Variables
- func Del(name string)
- func Exists(name string) bool
- func GenerateSessionID(prefix ...string) string
- func Get(name string) sessions.Store
- func NewMySession(store sessions.Store, name string, ctx echo.Context) echo.Sessioner
- func NewSession(ctx echo.Context) echo.Sessioner
- func Reg(name string, store sessions.Store)
- func StoreEngine(options *echo.SessionOptions) (store sessions.Store)
- type Closer
- type Session
- func (s *Session) AddFlash(value interface{}, vars ...string) echo.Sessioner
- func (s *Session) AddPreSaveHook(hook func(echo.Context) error)
- func (s *Session) Clear() echo.Sessioner
- func (s *Session) Delete(key string) echo.Sessioner
- func (s *Session) Flashes(vars ...string) []interface{}
- func (s *Session) Get(key string) interface{}
- func (s *Session) ID() string
- func (s *Session) MustID() string
- func (s *Session) RemoveID(sessionID string) error
- func (s *Session) Save() error
- func (s *Session) Session() *sessions.Session
- func (s *Session) Set(key string, val interface{}) echo.Sessioner
- func (s *Session) SetID(id string, notReload ...bool) error
- func (s *Session) SetPreSaveHook(hooks ...func(echo.Context) error)
- func (s *Session) Written() bool
- type Stores
Constants ¶
View Source
const ( DefaultMaxAge = 86400 * 30 // 30days EmptyDataAge = 3600 // 1hour )
Defaults for sessions.Options
Variables ¶
View Source
var ErrInvalidSessionID = errors.New("invalid session ID")
Functions ¶
func GenerateSessionID ¶ added in v1.6.0
func NewMySession ¶
func StoreEngine ¶
func StoreEngine(options *echo.SessionOptions) (store sessions.Store)
Types ¶
type Session ¶
type Session struct {
// contains filtered or unexported fields
}
func (*Session) AddPreSaveHook ¶ added in v1.6.0
func (*Session) SetPreSaveHook ¶ added in v1.6.0
Click to show internal directories.
Click to hide internal directories.