Documentation ¶
Index ¶
- func GenerateSchema(outfile string) error
- func MigrateSchemas(schemas ...string) error
- type GormSQLPrinter
- func (gsp *GormSQLPrinter) Error(ctx context.Context, msg string, data ...any)
- func (gsp *GormSQLPrinter) Info(ctx context.Context, msg string, data ...any)
- func (gsp *GormSQLPrinter) LogMode(level logger.LogLevel) logger.Interface
- func (gsp *GormSQLPrinter) ParamsFilter(ctx context.Context, sql string, params ...any) (string, []any)
- func (gsp *GormSQLPrinter) Printf(msg string, data ...any)
- func (gsp *GormSQLPrinter) SQL() string
- func (gsp *GormSQLPrinter) Trace(ctx context.Context, begin time.Time, fc func() (string, int64), err error)
- func (gsp *GormSQLPrinter) Warn(ctx context.Context, msg string, data ...any)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateSchema ¶
func MigrateSchemas ¶
Types ¶
type GormSQLPrinter ¶
type GormSQLPrinter struct {
// contains filtered or unexported fields
}
func (*GormSQLPrinter) Error ¶
func (gsp *GormSQLPrinter) Error(ctx context.Context, msg string, data ...any)
Error print error messages
func (*GormSQLPrinter) Info ¶
func (gsp *GormSQLPrinter) Info(ctx context.Context, msg string, data ...any)
Info print info
func (*GormSQLPrinter) LogMode ¶
func (gsp *GormSQLPrinter) LogMode(level logger.LogLevel) logger.Interface
LogMode log mode
func (*GormSQLPrinter) ParamsFilter ¶
func (gsp *GormSQLPrinter) ParamsFilter(ctx context.Context, sql string, params ...any) (string, []any)
Trace print sql message
func (*GormSQLPrinter) Printf ¶
func (gsp *GormSQLPrinter) Printf(msg string, data ...any)
func (*GormSQLPrinter) SQL ¶
func (gsp *GormSQLPrinter) SQL() string
Click to show internal directories.
Click to hide internal directories.