repository

package
v0.1.29 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2022 License: LGPL-2.1 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigRepositoryBuilder

type ConfigRepositoryBuilder interface {
	SetNamespace(namespace string) ConfigRepositoryBuilder
	Build() config_repository.ConfigRepository
}

type ContactRepositoryBuilder added in v0.1.20

type ContactRepositoryBuilder interface {
	SetNamespace(namespace string) ContactRepositoryBuilder
	Build() contact_repository.ContactRepository
}

type Repository

type Repository interface {
	Liveness(ctx context.Context) error
	UserRepositoryBuilder() UserRepositoryBuilder
	TokenRepositoryBuilder() TokenRepositoryBuilder
	ConfigRepositoryBuilder() ConfigRepositoryBuilder
	VerificationRepositoryBuilder() VerificationRepositoryBuilder
	ContactRepositoryBuilder() ContactRepositoryBuilder
	RemoveCollections(ctx context.Context, namespace string) error
	SetDefaultConfig(config *go_nuntio.HeraConfig)
	BuildIndexes(ctx context.Context, namespace string) error
}

func New

func New(ctx context.Context, environment *environment.Environment, crypto cryptox.Crypto, mongoClient *mongo.Client, logger *zap.Logger) (Repository, error)

type TokenRepositoryBuilder

type TokenRepositoryBuilder interface {
	SetNamespace(namespace string) TokenRepositoryBuilder
	Build() token_repository.TokenRepository
}

type UserRepositoryBuilder

type UserRepositoryBuilder interface {
	SetNamespace(namespace string) UserRepositoryBuilder
	WithPasswordValidation(validatePassword bool) UserRepositoryBuilder
	Build() user_repository.UserRepository
}

func NewUserRepositoryBuilder

func NewUserRepositoryBuilder(client *mongo.Client, defaultDb string, crypto cryptox.Crypto) UserRepositoryBuilder

NewUserRepositoryBuilder is used in other projects like Mercury

type VerificationRepositoryBuilder

type VerificationRepositoryBuilder interface {
	SetNamespace(namespace string) VerificationRepositoryBuilder
	Build() verification_repository.VerificationRepository
}

Jump to

Keyboard shortcuts

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