transaction

package
v0.0.30 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Begin

func Begin()

func Commit

func Commit() error

func End

func End() error

func Rollback

func Rollback()

func Session

func Session() *gorm.DB

Types

type DBSession

type DBSession struct {
	*gorm.DB
	// contains filtered or unexported fields
}

type TransactionManager

type TransactionManager struct {
	*gorm.DB `inject:"database"`
	// contains filtered or unexported fields
}

func (*TransactionManager) BeginTransaction

func (m *TransactionManager) BeginTransaction()

func (*TransactionManager) Commit

func (m *TransactionManager) Commit() error

func (*TransactionManager) EndTransaction

func (m *TransactionManager) EndTransaction() error

func (*TransactionManager) InTransaction

func (m *TransactionManager) InTransaction() bool

func (*TransactionManager) Rollback

func (m *TransactionManager) Rollback()

func (*TransactionManager) Session

func (m *TransactionManager) Session() *gorm.DB

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL