Versions in this module Expand all Collapse all v0 v0.1.1 Aug 26, 2022 Changes in this version + type Builder interface + Debug func(ctx context.Context) Core + Group func(ctx context.Context, name string) Core + Joins func(ctx context.Context, query string, args ...interface{}) Core + Limit func(ctx context.Context, limit int) Core + Model func(ctx context.Context, value interface{}) Core + Not func(ctx context.Context, query interface{}, args ...interface{}) Core + Offset func(ctx context.Context, offset int) Core + Or func(ctx context.Context, query interface{}, args ...interface{}) Core + Order func(ctx context.Context, value interface{}) Core + Raw func(ctx context.Context, sql string, values ...interface{}) Core + Select func(ctx context.Context, query interface{}, args ...interface{}) Core + Unscoped func(ctx context.Context) Core + Where func(ctx context.Context, query interface{}, args ...interface{}) Core + type Core interface + Count func(ctx context.Context, count *int64) error + Delete func(ctx context.Context, value interface{}, conds ...interface{}) error + Exec func(ctx context.Context, query string, args ...interface{}) (rst sql.Result, err error) + Find func(ctx context.Context, dest interface{}, conds ...interface{}) error + First func(ctx context.Context, dest interface{}, conds ...interface{}) error + Insert func(ctx context.Context, value interface{}) error + InsertBulk func(ctx context.Context, value interface{}, batchSize int) error + InsertBulkIgnore func(ctx context.Context, value interface{}, batchSize int) error + InsertIgnore func(ctx context.Context, value interface{}) error + Query func(ctx context.Context, query string, args ...interface{}) (rows *Rows, err error) + QueryRow func(ctx context.Context, query string, args ...interface{}) (row *Row, err error) + Update func(ctx context.Context, column string, value interface{}) error + Updates func(ctx context.Context, value map[string]interface{}) error + type ORM struct + func (x *ORM) Count(ctx context.Context, count *int64) error + func (x *ORM) Debug(ctx context.Context) Core + func (x *ORM) Delete(ctx context.Context, value interface{}, conds ...interface{}) error + func (x *ORM) Exec(ctx context.Context, query string, args ...interface{}) (rst sql.Result, err error) + func (x *ORM) Find(ctx context.Context, dest interface{}, conds ...interface{}) error + func (x *ORM) First(ctx context.Context, dest interface{}, conds ...interface{}) error + func (x *ORM) Group(ctx context.Context, name string) Core + func (x *ORM) Insert(ctx context.Context, value interface{}) error + func (x *ORM) InsertBulk(ctx context.Context, value interface{}, batchSize int) error + func (x *ORM) InsertBulkIgnore(ctx context.Context, value interface{}, batchSize int) error + func (x *ORM) InsertIgnore(ctx context.Context, value interface{}) error + func (x *ORM) Joins(ctx context.Context, query string, args ...interface{}) Core + func (x *ORM) Limit(ctx context.Context, limit int) Core + func (x *ORM) Model(ctx context.Context, value interface{}) Core + func (x *ORM) Not(ctx context.Context, query interface{}, args ...interface{}) Core + func (x *ORM) Offset(ctx context.Context, offset int) Core + func (x *ORM) Or(ctx context.Context, query interface{}, args ...interface{}) Core + func (x *ORM) Order(ctx context.Context, value interface{}) Core + func (x *ORM) Query(ctx context.Context, query string, args ...interface{}) (*Rows, error) + func (x *ORM) QueryRow(ctx context.Context, query string, args ...interface{}) (*Row, error) + func (x *ORM) Raw(ctx context.Context, sql string, values ...interface{}) Core + func (x *ORM) Select(ctx context.Context, query interface{}, args ...interface{}) Core + func (x *ORM) Tx(ctx context.Context, f func(context.Context) error) error + func (x *ORM) Unscoped(ctx context.Context) Core + func (x *ORM) Update(ctx context.Context, column string, value interface{}) error + func (x *ORM) Updates(ctx context.Context, value map[string]interface{}) error + func (x *ORM) Where(ctx context.Context, query interface{}, args ...interface{}) Core + type ORMItf interface + Tx func(ctx context.Context, f func(context.Context) error) error + func New(orm *gorm.DB) ORMItf + type Row struct + func (r *Row) Scan(desc ...interface{}) error + type Rows struct + func (r *Rows) Scan(desc ...interface{}) error + type TxORM struct + func (x *TxORM) Commit() error + func (x *TxORM) Count(ctx context.Context, count *int64) error + func (x *TxORM) Debug(_ context.Context) Core + func (x *TxORM) Delete(ctx context.Context, value interface{}, conds ...interface{}) error + func (x *TxORM) Exec(ctx context.Context, query string, args ...interface{}) (rst sql.Result, err error) + func (x *TxORM) Find(ctx context.Context, dest interface{}, conds ...interface{}) error + func (x *TxORM) First(ctx context.Context, dest interface{}, conds ...interface{}) error + func (x *TxORM) Group(_ context.Context, name string) Core + func (x *TxORM) Insert(ctx context.Context, value interface{}) error + func (x *TxORM) InsertBulk(ctx context.Context, value interface{}, batchSize int) error + func (x *TxORM) InsertBulkIgnore(ctx context.Context, value interface{}, batchSize int) error + func (x *TxORM) InsertIgnore(ctx context.Context, value interface{}) error + func (x *TxORM) Joins(_ context.Context, query string, args ...interface{}) Core + func (x *TxORM) Limit(_ context.Context, limit int) Core + func (x *TxORM) Model(_ context.Context, value interface{}) Core + func (x *TxORM) Not(_ context.Context, query interface{}, args ...interface{}) Core + func (x *TxORM) Offset(_ context.Context, offset int) Core + func (x *TxORM) Or(_ context.Context, query interface{}, args ...interface{}) Core + func (x *TxORM) Order(_ context.Context, value interface{}) Core + func (x *TxORM) Query(ctx context.Context, query string, args ...interface{}) (*Rows, error) + func (x *TxORM) QueryRow(ctx context.Context, query string, args ...interface{}) (*Row, error) + func (x *TxORM) Raw(_ context.Context, sql string, values ...interface{}) Core + func (x *TxORM) Rollback() error + func (x *TxORM) Select(_ context.Context, query interface{}, args ...interface{}) Core + func (x *TxORM) Tx(f func() error) (err error) + func (x *TxORM) Unscoped(_ context.Context) Core + func (x *TxORM) Update(ctx context.Context, column string, value interface{}) error + func (x *TxORM) Updates(ctx context.Context, value map[string]interface{}) error + func (x *TxORM) Where(_ context.Context, query interface{}, args ...interface{}) Core + type TxORMItf interface + Commit func() error + Rollback func() error + Tx func(f func() error) error