mongo

package
v0.4.15 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2024 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 Mongo

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

Mongo contains functions for genre mongodb.

func New

func New(mdb *mongo.Database) *Mongo

New to create new genre database.

func (*Mongo) BatchUpdate

func (m *Mongo) BatchUpdate(ctx context.Context, data []entity.Genre) (int, error)

BatchUpdate to batch update.

func (*Mongo) GetAll added in v0.2.0

func (m *Mongo) GetAll(ctx context.Context, data entity.GetAllRequest) ([]entity.Genre, int, int, error)

GetAll to get all.

func (*Mongo) GetByID added in v0.3.0

func (m *Mongo) GetByID(ctx context.Context, id int64) (*entity.Genre, int, error)

GetByID to get by id.

Jump to

Keyboard shortcuts

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