gorm_plugin

package
Version: v1.3.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 23, 2021 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigAdapter added in v1.3.7

type ConfigAdapter struct {
	bean.Component
	Level                  string `yaml:"loglevel"`
	SkipDefaultTransaction bool   `yaml:"skip_default_transaction"`
	NamingStrategy         struct {
		TablePrefix   string `yaml:"table_prefix"`
		SingularTable bool   `yaml:"singular_table"`
	} `yaml:"naming_strategy"`
	FullSaveAssociations                     bool `yaml:"full_save_associations"`
	DryRun                                   bool `yaml:"dry_run"`
	PrepareStmt                              bool `yaml:"prepare_stmt"`
	DisableAutomaticPing                     bool `yaml:"disable_automatic_ping"`
	DisableForeignKeyConstraintWhenMigrating bool `yaml:"disable_foreign_key_constraint_when_migrating"`
	DisableNestedTransaction                 bool `yaml:"disable_nested_transaction"`
	AllowGlobalUpdate                        bool `yaml:"allow_global_update"`
	QueryFields                              bool `yaml:"query_fields"`
	CreateBatchSize                          int  `yaml:"create_batch_size"`
}

func (*ConfigAdapter) Prefix added in v1.3.7

func (g *ConfigAdapter) Prefix() string

func (*ConfigAdapter) ToGormConfig added in v1.3.7

func (g *ConfigAdapter) ToGormConfig() *gorm.Config

type GormLoggerAdapter added in v1.1.8

type GormLoggerAdapter struct {
	LogLevel
	SlowThreshold time.Duration
	// contains filtered or unexported fields
}

func NewGormLoggerAdapter added in v1.1.8

func NewGormLoggerAdapter(logger *GormLoggerAdapter) *GormLoggerAdapter

func (*GormLoggerAdapter) Error added in v1.1.8

func (g *GormLoggerAdapter) Error(ctx context.Context, s string, i ...interface{})

func (*GormLoggerAdapter) Info added in v1.1.8

func (g *GormLoggerAdapter) Info(ctx context.Context, s string, i ...interface{})

func (*GormLoggerAdapter) LogMode added in v1.1.8

func (g *GormLoggerAdapter) LogMode(level LogLevel) Interface

func (*GormLoggerAdapter) Trace added in v1.1.8

func (g *GormLoggerAdapter) Trace(ctx context.Context, begin time.Time, fc func() (string, int64), err error)

func (*GormLoggerAdapter) Warn added in v1.1.8

func (g *GormLoggerAdapter) Warn(ctx context.Context, s string, i ...interface{})

type GormUpgrader added in v1.3.8

type GormUpgrader struct {
	bean.Component
}

func NewGormUpgrader added in v1.3.8

func NewGormUpgrader() *GormUpgrader

func (*GormUpgrader) Upgrade added in v1.3.8

func (g *GormUpgrader) Upgrade(wrapper datasource.Wrapper) (interface{}, error)

func (*GormUpgrader) UpgradeType added in v1.3.8

func (g *GormUpgrader) UpgradeType() reflect.Type

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL