session

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2021 License: GPL-3.0 Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Locale = "cn"
	Domain = "internal"
)

Functions

This section is empty.

Types

type Manager

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

func NewManager

func NewManager(client *client.Client) *Manager

func (*Manager) Login

func (sm *Manager) Login(ctx context.Context, u *url.Userinfo) error

func (*Manager) Logout

func (sm *Manager) Logout(ctx context.Context) error

func (*Manager) UserSession

func (sm *Manager) UserSession(ctx context.Context) (*types.UserSession, error)

UserSession retrieves and returns the SessionManager's CurrentSession field. Nil is returned if the session is not authenticated.

Jump to

Keyboard shortcuts

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