Documentation ¶
Index ¶
- type Client
- type Collection
- func (c *Collection) Aggregate(ctx context.Context, pipes []bson.D, data any) error
- func (c *Collection) DeleteMany(ctx context.Context, filter bson.M) error
- func (c *Collection) DeleteOne(ctx context.Context, filter bson.M) error
- func (c *Collection) Find(ctx context.Context, filter bson.M, data any) error
- func (c *Collection) FindByID(ctx context.Context, id string, data any) error
- func (c *Collection) InsertMany(ctx context.Context, docs []any) error
- func (c *Collection) InsertOne(ctx context.Context, doc any) error
- func (c *Collection) ReplaceOne(ctx context.Context, filter bson.M, data any) error
- func (c *Collection) UpdateMany(ctx context.Context, filter bson.M, data any) error
- func (c *Collection) UpdateOne(ctx context.Context, filter bson.M, data any) error
- type DB
- type Document
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) Transaction ¶
func (c *Client) Transaction(fn func(sessionContext mongo.SessionContext) error) error
type Collection ¶
type Collection struct {
// contains filtered or unexported fields
}
func (*Collection) DeleteMany ¶
func (*Collection) InsertMany ¶
func (c *Collection) InsertMany(ctx context.Context, docs []any) error
func (*Collection) ReplaceOne ¶
func (*Collection) UpdateMany ¶
Click to show internal directories.
Click to hide internal directories.