mongo

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2023 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MongoRepository

type MongoRepository struct {
	DatabaseCollection *mongo.Collection
}

func NewRepository

func NewRepository(c *mongo.Client) (*MongoRepository, error)

func (*MongoRepository) BuildIndexes

func (r *MongoRepository) BuildIndexes(ctx context.Context) error

func (*MongoRepository) Create

func (m *MongoRepository) Create(ctx context.Context, database *database.Database) (*database.Database, error)

func (*MongoRepository) Delete

func (m *MongoRepository) Delete(ctx context.Context, databaseID uuid.UUID) error

func (*MongoRepository) Get

func (m *MongoRepository) Get(ctx context.Context, databaseID uuid.UUID) (*database.Database, error)

func (*MongoRepository) GetByName

func (m *MongoRepository) GetByName(ctx context.Context, name string) (*database.Database, error)

func (*MongoRepository) List

List implements group_repository.GroupRepository

func (*MongoRepository) Update

func (m *MongoRepository) Update(ctx context.Context, database *database.Database) (*database.Database, error)

Update updates the name of a specific group.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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