Documentation ¶
Overview ¶
Example (PkgLevelTxFunctions) ¶
package main import ( "context" "github.com/adamluzsi/frameless/pkg/txs" ) func main() { ctx := context.Background() _ = func(ctx context.Context) (rerr error) { tx, _ := txs.Begin(ctx) defer txs.Finish(&rerr, tx) txs.OnRollback(tx, func() { // something to do }) return nil }(ctx) }
Output:
Index ¶
Examples ¶
Constants ¶
Variables ¶
This section is empty.
Functions ¶
func OnRollback ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.