repository

package
v0.0.0-...-aff41f5 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateUserParams

type CreateUserParams struct{}

type Repository

type Repository interface {
	// FindUserByID finds a user by id
	FindUserByID(ctx context.Context, id string) (models.User, error)

	// FindUserByEmail finds a user by email
	FindUserByEmail(ctx context.Context, email string) (models.User, error)

	// CreateUser creates a new user
	CreateUser(ctx context.Context, params models.User) (models.User, error)

	// DeleteUser deletes an existing user
	DeleteUser(ctx context.Context, id string) error
}

Repository is the interface that provides user related methods

func NewRepository

func NewRepository(writerDB *pgxpool.Pool, readerDB *pgxpool.Pool) Repository

Jump to

Keyboard shortcuts

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