simple

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Code generated by mongox, DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	DB   *mongo.Client
	User *user.UserClient
}

Client .

func NewClient

func NewClient(db *mongo.Client) *Client

NewClient .

func Open

func Open(uri string) (*Client, error)

Open .

func (*Client) ListDatabaseNames

func (c *Client) ListDatabaseNames(ctx context.Context, filter filters.Filter, opts ...*options.ListDatabasesOptions) ([]string, error)

ListDatabaseNames .

func (*Client) ListDatabases

func (c *Client) ListDatabases(ctx context.Context, filter filters.Filter, opts ...*options.ListDatabasesOptions) (mongo.ListDatabasesResult, error)

ListDatabases .

func (*Client) UseSession

func (c *Client) UseSession(ctx context.Context, opts *options.SessionOptions, fn func(sessionContext mongo.SessionContext) error) error

UseSession .

func (*Client) Watch

func (c *Client) Watch(ctx context.Context, pipeline watch.WatchPipe, opts ...*options.ChangeStreamOptions) (*mongo.ChangeStream, error)

Watch .

func (*Client) WithTransaction

func (c *Client) WithTransaction(ctx context.Context, fn func(sessCtx mongo.SessionContext) (interface{}, error), opts ...*options.TransactionOptions) (interface{}, error)

WithTransaction .

Directories

Path Synopsis
Code generated by mongox, DO NOT EDIT.
Code generated by mongox, DO NOT EDIT.

Jump to

Keyboard shortcuts

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