sessions

package
v0.0.0-...-7647e70 Latest Latest
Warning

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

Go to latest
Published: May 8, 2024 License: MIT Imports: 16 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileSessionData

type FileSessionData struct {
	Sid       string            `json:"sid"`
	ExpiredAt uint              `json:"expiredAt"`
	Values    map[string]string `json:"values"`
	AccessAt  uint              `json:"accessAt"`
}

type FileSessionManager

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

func NewFileSessionManager

func NewFileSessionManager(lifeSeconds uint, encryptKey string) *FileSessionManager

func (*FileSessionManager) Delete

func (this *FileSessionManager) Delete(sid string) bool

func (*FileSessionManager) Init

func (this *FileSessionManager) Init(config *actions.SessionConfig)

func (*FileSessionManager) Read

func (this *FileSessionManager) Read(sid string) map[string]string

func (*FileSessionManager) SetDir

func (this *FileSessionManager) SetDir(dir string)

func (*FileSessionManager) WriteItem

func (this *FileSessionManager) WriteItem(sid string, key string, value string) bool

type MemorySessionManager

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

func NewMemorySessionManager

func NewMemorySessionManager() *MemorySessionManager

func (*MemorySessionManager) Delete

func (this *MemorySessionManager) Delete(sid string) bool

func (*MemorySessionManager) Init

func (this *MemorySessionManager) Init(config *actions.SessionConfig)

func (*MemorySessionManager) Read

func (this *MemorySessionManager) Read(sid string) map[string]string

func (*MemorySessionManager) WriteItem

func (this *MemorySessionManager) WriteItem(sid string, key string, value string) bool

Jump to

Keyboard shortcuts

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