users

package
v0.0.0-...-dcf7d21 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2021 License: GPL-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type User

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

func NewUser

func NewUser(userid, cryptword string, perms *permissions.Permissions) *User

func (*User) Cryptword

func (u *User) Cryptword() string

func (*User) HasPermission

func (u *User) HasPermission(perm permissions.Permission) bool

func (*User) Id

func (u *User) Id() string

func (*User) PermissionsString

func (u *User) PermissionsString() string

func (*User) SetCryptword

func (u *User) SetCryptword(cryptword string)

type Users

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

func Empty

func Empty() *Users

func LoadFile

func LoadFile(filename string) (*Users, error)

func (*Users) Cryptword

func (m *Users) Cryptword(userid string) string

func (*Users) HasPermission

func (m *Users) HasPermission(userid string, perm permissions.Permission) bool

func (*Users) SaveFile

func (m *Users) SaveFile(filename string) error

func (*Users) SetCryptword

func (m *Users) SetCryptword(userid, cryptword string)

func (*Users) User

func (m *Users) User(userid string) *User

func (*Users) UserCount

func (m *Users) UserCount() int

Jump to

Keyboard shortcuts

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