Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IAdapter ¶
type IAdapter interface { Count(ctx context.Context, query interface{}) (int64, error) Find( ctx context.Context, query interface{}, docs interface{}, opts ...interface{}, ) (err error) FindOne( ctx context.Context, query interface{}, doc interface{}, opts ...interface{}, ) (err error) Insert( ctx context.Context, doc interface{}, ) (insertedID interface{}, err error) InsertMany( ctx context.Context, docs []interface{}, ) (insertedIDs []interface{}, err error) Update( ctx context.Context, query interface{}, update interface{}, ) (res *UpdateSummary, err error) UpdateMany( ctx context.Context, query interface{}, update interface{}, ) (res *UpdateSummary, err error) Delete(ctx context.Context, filter interface{}) (delCount int64, err error) DeleteMany(ctx context.Context, filter interface{}) (delCount int64, err error) }
IAdapter indicates the interface of the adapter.
type UpdateSummary ¶
type UpdateSummary struct { MatchedCount int64 ModifiedCount int64 UpsertedCount int64 UpsertedIDs interface{} }
UpdateSummary represents a structure that tells the result of update/upsert.
Click to show internal directories.
Click to hide internal directories.