Documentation ¶
Index ¶
- func ReplaceObjectIds(data interface{}) interface{}
- type Datasource
- func (ds *Datasource) Create(collectionName string, data *wst.M) (*mongo.Cursor, error)
- func (ds *Datasource) DeleteById(collectionName string, id interface{}) int64
- func (ds *Datasource) FindById(collectionName string, id interface{}, filter *wst.Filter, lookups *wst.A) *mongo.Cursor
- func (ds *Datasource) FindMany(collectionName string, filter *wst.Filter, lookups *wst.A) *mongo.Cursor
- func (ds *Datasource) Initialize() error
- func (ds *Datasource) UpdateById(collectionName string, id interface{}, data *wst.M) *mongo.Cursor
- type OperationError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReplaceObjectIds ¶ added in v1.2.12
func ReplaceObjectIds(data interface{}) interface{}
Types ¶
type Datasource ¶
func New ¶
func New(config wst.M) *Datasource
func (*Datasource) DeleteById ¶
func (ds *Datasource) DeleteById(collectionName string, id interface{}) int64
func (*Datasource) Initialize ¶
func (ds *Datasource) Initialize() error
func (*Datasource) UpdateById ¶
type OperationError ¶
func NewError ¶
func NewError(code int, message string) *OperationError
func (*OperationError) Error ¶
func (e *OperationError) Error() string
Click to show internal directories.
Click to hide internal directories.