mongo_helper

package
v0.0.0-...-de2e23a Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collection

type Collection struct {
	Col *mongo.Collection
}

func NewCollection

func NewCollection(c *mongo.Collection) *Collection

func (*Collection) DeleteOneById

func (c *Collection) DeleteOneById(id string) error

func (*Collection) FindAll

func (c *Collection) FindAll(results interface{}) error

func (*Collection) FindOneById

func (c *Collection) FindOneById(id string, result interface{}) error

func (*Collection) InsertOne

func (c *Collection) InsertOne(document interface{}) (primitive.ObjectID, error)

Jump to

Keyboard shortcuts

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