Documentation ¶
Index ¶
- Variables
- func IsUniqueIndexConflictErr(err error) bool
- type Client
- func (p *Client) AutoMigrate(dst ...interface{}) error
- func (p *Client) Begin() *gorm.DB
- func (p *Client) Clauses(conds ...clause.Expression) *gorm.DB
- func (p *Client) CommitOrRollback(tx *gorm.DB, logic func() error) error
- func (p *Client) Create(value interface{}) *gorm.DB
- func (p *Client) CreateInBatches(value interface{}, batchSize int) *gorm.DB
- func (p *Client) Find(dest interface{}, conds ...interface{}) *gorm.DB
- func (p *Client) FindInBatches(dest interface{}, batchSize int, fc func(tx *gorm.DB, batch int) error) *gorm.DB
- func (p *Client) FirstOrCreate(dest interface{}, conds ...interface{}) (tx *gorm.DB)
- func (p *Client) Model(model interface{}) *gorm.DB
- func (p *Client) Order(value interface{}) *gorm.DB
- func (p *Client) Save(value interface{}) *gorm.DB
- func (p *Client) Select(query interface{}, args ...interface{}) *gorm.DB
- func (p *Client) Statement() *gorm.Statement
- func (p *Client) Transaction(logic func(tx *gorm.DB) error) error
- func (p *Client) Unscoped() *gorm.DB
- func (p *Client) Where(query interface{}, args ...interface{}) *gorm.DB
- type Config
- type Database
- type Logger
- func (l *Logger) Error(ctx context.Context, s string, i ...interface{})
- func (l *Logger) Info(ctx context.Context, s string, i ...interface{})
- func (l *Logger) LogMode(logLevel logger.LogLevel) logger.Interface
- func (l *Logger) Trace(ctx context.Context, begin time.Time, ...)
- func (l *Logger) Warn(ctx context.Context, s string, i ...interface{})
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrBatchesStop = errors.New("batches stop")
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) AutoMigrate ¶
func (*Client) CommitOrRollback ¶
func (*Client) CreateInBatches ¶
func (*Client) FindInBatches ¶
func (*Client) FirstOrCreate ¶
Click to show internal directories.
Click to hide internal directories.