repository

package
v0.0.0-...-2fa74ab Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UserRepository

type UserRepository interface {
	// GetAllUsers retrieves all users from the database.
	GetAllUsers(ctx context.Context) ([]model.User, error)
	// GetUserByID retrieves a user by their ID.
	GetUserByID(ctx context.Context, id string) (*model.User, error)
	// CreateUser adds a new user to the database.
	CreateUser(ctx context.Context, user *model.User) error
	// UpdateUser modifies an existing user's details.
	UpdateUser(ctx context.Context, user *model.User) error
	// DeleteUser removes a user from the database.
	DeleteUser(ctx context.Context, id string) error
}

UserRepository defines the methods for user data access.

func NewUserRepository

func NewUserRepository() UserRepository

Jump to

Keyboard shortcuts

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