factory

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeNamespace = "namespace"
	TypeUser      = "user"
	TypeRole      = "role"
	TypeRule      = "rule"
	TypeSession   = "session"
	TypeIdentity  = "identity"
	TypeAccess    = "access"
)

Variables

This section is empty.

Functions

func IntializeBackend

func IntializeBackend(db *gorm.DB) error

func NewAccess

func NewAccess(ctx context.Context, namespace string) (*domain.Access, error)

func NewIdentity

func NewIdentity(ctx context.Context, namespace string) (*domain.Identity, error)

func NewMetadata

func NewMetadata(namespace, name, typ string) domain.Metadata

func NewNamespace

func NewNamespace(ctx context.Context, namespaceName string) (*domain.Namespace, error)

func NewRole

func NewRole(ctx context.Context, namespace string) (*domain.Role, error)

func NewRule

func NewRule(ctx context.Context, namespace string) (*domain.Rule, error)

func NewSession

func NewSession(ctx context.Context, identityID uint, namespace string) (*domain.Session, error)

func NewUser

func NewUser(ctx context.Context, namespace string) (*domain.User, error)

func NewUserName

func NewUserName(ctx context.Context, namespace string, name string) (string, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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