Documentation ¶
Index ¶
- type Store
- func (s *Store) Close() error
- func (store *Store) Get(r *http.Request, name string) (*sessions.Session, error)
- func (store *Store) MaxAge(age int)
- func (store *Store) New(r *http.Request, name string) (*sessions.Session, error)
- func (store *Store) Save(r *http.Request, w http.ResponseWriter, session *sessions.Session) error
- type StoreOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
func (*Store) MaxAge ¶
MaxAge sets the maximum age for the store and the underlying cookie implementation. Individual sessions can be deleted by setting Options.MaxAge = -1 for that session.
type StoreOption ¶ added in v0.1.1
type StoreOption func(s *Store)
func WithGCDisabled ¶
func WithGCDisabled() StoreOption
func WithGCInterval ¶
func WithGCInterval(gcInterval time.Duration) StoreOption
func WithInitTableDisabled ¶
func WithInitTableDisabled() StoreOption
func WithKeyPairs ¶
func WithKeyPairs(keyPairs ...[]byte) StoreOption
func WithSecureDisabled ¶
func WithSecureDisabled() StoreOption
WithSecureDisabled encode session values as JSON, ONLY for development
func WithTableName ¶
func WithTableName(tableName string) StoreOption
Click to show internal directories.
Click to hide internal directories.