mocks

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2024 License: Apache-2.0, Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Database

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

func NewDatabase

func NewDatabase() *Database

func (*Database) Disconnect

func (this *Database) Disconnect()

func (*Database) GetImportType

func (this *Database) GetImportType(ctx context.Context, id string) (importType model.ImportType, exists bool, err error)

func (*Database) RemoveImportType

func (this *Database) RemoveImportType(ctx context.Context, id string) error

func (*Database) SetImportType

func (this *Database) SetImportType(ctx context.Context, importType model.ImportType) error

type Security

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

func NewSecurity

func NewSecurity() *Security

func (*Security) CheckBool

func (this *Security) CheckBool(jwt auth.Token, kind string, id string, action model.AuthAction) (allowed bool, err error)

func (*Security) CheckMultiple

func (this *Security) CheckMultiple(jwt auth.Token, kind string, ids []string, action model.AuthAction) (map[string]bool, error)

func (*Security) GetAsUser

func (this *Security) GetAsUser(jwt auth.Token, url string, result *[]interface{}) (err error)

func (*Security) Set

func (this *Security) Set(kind string, id string, access bool)

Jump to

Keyboard shortcuts

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