Documentation ¶
Index ¶
- type MongoDbClient
- func (m *MongoDbClient) Client() *mongo.Client
- func (m *MongoDbClient) Config() interface{}
- func (m *MongoDbClient) Context() context.Context
- func (m *MongoDbClient) DbName() string
- func (m *MongoDbClient) Init(app app_context.Context, configPath ...string) error
- func (m *MongoDbClient) Name() string
- func (m *MongoDbClient) Shutdown(ctx context.Context) error
- type MongoDbClientConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MongoDbClient ¶
type MongoDbClient struct { MongoDbClientConfig // contains filtered or unexported fields }
func New ¶
func New(name string, defaultDbName ...string) *MongoDbClient
func (*MongoDbClient) Client ¶
func (m *MongoDbClient) Client() *mongo.Client
func (*MongoDbClient) Config ¶
func (m *MongoDbClient) Config() interface{}
func (*MongoDbClient) Context ¶
func (m *MongoDbClient) Context() context.Context
func (*MongoDbClient) DbName ¶
func (m *MongoDbClient) DbName() string
func (*MongoDbClient) Init ¶
func (m *MongoDbClient) Init(app app_context.Context, configPath ...string) error
func (*MongoDbClient) Name ¶
func (m *MongoDbClient) Name() string
type MongoDbClientConfig ¶
Click to show internal directories.
Click to hide internal directories.