session

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 10, 2018 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EtcdStore

type EtcdStore struct {
	// contains filtered or unexported fields
}

func NewEtcdStore

func NewEtcdStore(cli *cronsun.Client, conf conf.SessionConfig) *EtcdStore

func (*EtcdStore) CleanSeesionData

func (this *EtcdStore) CleanSeesionData(id string)

func (*EtcdStore) Destroy

func (this *EtcdStore) Destroy(w http.ResponseWriter, r *http.Request)

func (*EtcdStore) Get

func (this *EtcdStore) Get(w http.ResponseWriter, r *http.Request) (sess *Session, err error)

func (*EtcdStore) Store

func (this *EtcdStore) Store(sess *Session) (err error)

type Session

type Session struct {
	// contains filtered or unexported fields
}

func (*Session) ID

func (s *Session) ID() string

func (*Session) Store

func (s *Session) Store() error

type SessionManager

type SessionManager interface {
	Get(w http.ResponseWriter, r *http.Request) (*Session, error)
	Store(*Session) error
	Destroy(w http.ResponseWriter, r *http.Request)
	CleanSeesionData(id string)
}
var Manager SessionManager

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL