Documentation
¶
Index ¶
- Variables
- type MongoDemoEntity
- type MongoDemoSvc
- func (d *MongoDemoSvc) DeleteById(id interface{}) (bool, error)
- func (d *MongoDemoSvc) GetById(id interface{}) (*MongoDemoEntity, error)
- func (d *MongoDemoSvc) Insert(entities ...*MongoDemoEntity) ([]interface{}, error)
- func (d *MongoDemoSvc) SelectAll(mqp *svc.MongoQueryParams) (*[]MongoDemoEntity, error)
- func (d *MongoDemoSvc) SelectRegex(mqp *svc.MongoQueryParams) (*[]MongoDemoEntity, error)
- func (d *MongoDemoSvc) UpdateById(id interface{}, newEntity *MongoDemoEntity, updateFields map[string]bool) (error, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var MongoDemoEntityType reflect.Type = reflect.TypeOf(MongoDemoEntity{})
Functions ¶
This section is empty.
Types ¶
type MongoDemoEntity ¶
type MongoDemoEntity struct { svc.MongoBaseEntity Name string `bson:"name" json:"name"` Status int `bson:"status" json:"status"` }
type MongoDemoSvc ¶
type MongoDemoSvc struct {
*svc.MongoBaseSvc
}
func NewMongoDemoSvc ¶
func NewMongoDemoSvc(alogger golog.ILogger, mclient *mongo.Client) *MongoDemoSvc
func (*MongoDemoSvc) DeleteById ¶
func (d *MongoDemoSvc) DeleteById(id interface{}) (bool, error)
func (*MongoDemoSvc) GetById ¶
func (d *MongoDemoSvc) GetById(id interface{}) (*MongoDemoEntity, error)
func (*MongoDemoSvc) Insert ¶
func (d *MongoDemoSvc) Insert(entities ...*MongoDemoEntity) ([]interface{}, error)
func (*MongoDemoSvc) SelectAll ¶
func (d *MongoDemoSvc) SelectAll(mqp *svc.MongoQueryParams) (*[]MongoDemoEntity, error)
func (*MongoDemoSvc) SelectRegex ¶
func (d *MongoDemoSvc) SelectRegex(mqp *svc.MongoQueryParams) (*[]MongoDemoEntity, error)
func (*MongoDemoSvc) UpdateById ¶
func (d *MongoDemoSvc) UpdateById(id interface{}, newEntity *MongoDemoEntity, updateFields map[string]bool) (error, error)
Click to show internal directories.
Click to hide internal directories.