postgresminio

package
v0.0.0-...-0ca9650 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2023 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

func NewService

func NewService(pool *pgxpool.Pool, minioClient *minio.Client, bucketName string, objectPrefix string) *Service

func (*Service) CheckPassword

func (s *Service) CheckPassword(username string, password []byte) (ok bool, user *distrybute.User, err error)

func (*Service) CreateNewUser

func (s *Service) CreateNewUser(username string, password []byte) (user *distrybute.User, err error)

func (*Service) Delete

func (s *Service) Delete(deleteReference string) (err error)

func (*Service) DeleteUser

func (s *Service) DeleteUser(id uuid.UUID) (err error)

func (*Service) GetUserByAuthorizationToken

func (s *Service) GetUserByAuthorizationToken(token string) (bool, *distrybute.User, error)

func (*Service) GetUserByUsername

func (s *Service) GetUserByUsername(username string) (user *distrybute.User, err error)

func (Service) Init

func (s Service) Init() error

func (*Service) ListUsers

func (s *Service) ListUsers() (users []*distrybute.User, err error)

func (*Service) RefreshAuthorizationToken

func (s *Service) RefreshAuthorizationToken(id uuid.UUID) (token string, err error)

func (*Service) Request

func (s *Service) Request(callReference string) (entry *distrybute.FileEntry, err error)

func (*Service) ResolveAuthorizationToken

func (s *Service) ResolveAuthorizationToken(id uuid.UUID) (token string, err error)

func (*Service) Store

func (s *Service) Store(filename, contentType string, size int64, author uuid.UUID, reader io.Reader) (entry *distrybute.FileEntry, err error)

func (*Service) UpdatePassword

func (s *Service) UpdatePassword(id uuid.UUID, password []byte) (err error)

func (*Service) UpdateUsername

func (s *Service) UpdateUsername(id uuid.UUID, newUsername string) (err error)

Jump to

Keyboard shortcuts

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