scopes

package
v0.0.0-...-8f6ea6c Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scope

type Scope struct {
	Id primitive.ObjectID `bson:"_id,omitempty"`

	Name        string                        `bson:"name,omitempty"`
	Description string                        `bson:"description,omitempty"`
	Resources   resources.Resources           `bson:"resources,omitempty"`
	Permissions permissions.AccessPermissions `bson:"permissions,omitempty"`

	CreatedAt time.Time `bson:"created_at,omitempty"`
	UpdatedAt time.Time `bson:"updated_at,omitempty"`
}

type Scopes

type Scopes []Scope

type ScopesRepository

type ScopesRepository interface {
	GetScopeById(id string) (*Scope, error)
	GetScopeByName(name string) (*Scope, error)
	ListScopes() *[]Scope
	CreateScope(scope *Scope) error
	UpdateScope(id string, scope *Scope) error
	DeleteScope(id string) error
}

func GetScopesRepository

func GetScopesRepository() ScopesRepository

Jump to

Keyboard shortcuts

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