Documentation
¶
Index ¶
- Variables
- func MustGetSerialNumber(s *usersystem.Session) string
- type Active
- type ActiveSessions
- func (s *ActiveSessions) InstallProcess(ctx context.Context, system herbsystem.System, ...)
- func (s *ActiveSessions) ModuleName() string
- func (s *ActiveSessions) MustOnSessionActive(session *usersystem.Session)
- func (s *ActiveSessions) StartService() error
- func (s *ActiveSessions) StopService() error
- type Config
- type InstalledAcitveSessions
- type Service
Constants ¶
This section is empty.
Variables ¶
View Source
var ModuleName = "activesessionsmanager"
View Source
var PayloadSerialNumber = "sessionSerialNumber"
Functions ¶
func MustGetSerialNumber ¶
func MustGetSerialNumber(s *usersystem.Session) string
Types ¶
type ActiveSessions ¶
type ActiveSessions struct {
herbsystem.NopModule
Service
}
func MustGetModule ¶
func MustGetModule(s *usersystem.UserSystem) *ActiveSessions
func New ¶
func New() *ActiveSessions
func (*ActiveSessions) InstallProcess ¶
func (s *ActiveSessions) InstallProcess(ctx context.Context, system herbsystem.System, next func(context.Context, herbsystem.System))
func (*ActiveSessions) ModuleName ¶
func (s *ActiveSessions) ModuleName() string
func (*ActiveSessions) MustOnSessionActive ¶
func (s *ActiveSessions) MustOnSessionActive(session *usersystem.Session)
func (*ActiveSessions) StartService ¶
func (s *ActiveSessions) StartService() error
func (*ActiveSessions) StopService ¶
func (s *ActiveSessions) StopService() error
type InstalledAcitveSessions ¶
type InstalledAcitveSessions struct {
*ActiveSessions
UserSystem *usersystem.UserSystem
}
func MustNewAndInstallTo ¶
func MustNewAndInstallTo(s *usersystem.UserSystem) *InstalledAcitveSessions
func NewInstalledAcitveSessions ¶
func NewInstalledAcitveSessions() *InstalledAcitveSessions
func (*InstalledAcitveSessions) MustPurgeActiveSession ¶
func (s *InstalledAcitveSessions) MustPurgeActiveSession(session *usersystem.Session)
type Service ¶
type Service interface {
MustConfig(st usersystem.SessionType) *Config
MustOnSessionActive(session *usersystem.Session)
MustGetActiveSessions(usersystem.SessionType, string) []*Active
MustPurgeActiveSession(st usersystem.SessionType, uid string, serialnumber string)
MustCreateSerialNumber() string
Start() error
Stop() error
}
Click to show internal directories.
Click to hide internal directories.