client

package
v0.0.0-...-e0c2b11 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	NewClient() error
	ApplyURI(uri string)
	Ping(ctx context.Context, rp *readpref.ReadPref) error
	Database(name string, opts ...*options.DatabaseOptions) *mongo.Database
	Connect(ctx context.Context) error
	Disconnect(ctx context.Context) error
}

type MongoClient

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

func (*MongoClient) ApplyURI

func (mc *MongoClient) ApplyURI(uri string)

func (*MongoClient) Connect

func (mc *MongoClient) Connect(ctx context.Context) error

func (*MongoClient) Database

func (mc *MongoClient) Database(name string, opts ...*options.DatabaseOptions) *mongo.Database

func (*MongoClient) Disconnect

func (mc *MongoClient) Disconnect(ctx context.Context) error

func (*MongoClient) NewClient

func (mc *MongoClient) NewClient() error

func (*MongoClient) Ping

func (mc *MongoClient) Ping(ctx context.Context, rp *readpref.ReadPref) error

Jump to

Keyboard shortcuts

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