Documentation

ManagerInterface
in

Db adapter transaction manager interface

Tags
category

Pop

author

Nick Sagona, III dev@nolainteractive.com

author

Martok martok@martoks-place.de

copyright

Copyright (c) 2009-2024 NOLA Interactive, LLC. (http://www.nolainteractive.com)

license

http://www.popphp.org/license New BSD License

version
6.5.0

Table of Contents

Methods

enter()  : bool
Enter a new transaction or increase nesting level
getTransactionDepth()  : int
Get transaction depth
isTransaction()  : bool
Check if adapter is in the middle of an open transaction
leave()  : bool
Leave a transaction or reduce nesting level

Methods

enter()

Enter a new transaction or increase nesting level

public enter([callable|null $beginFunc = null ][, callable|null $savepointFunc = null ]) : bool
Parameters
$beginFunc : callable|null = null

Called when a new top-level transaction must be started

$savepointFunc : callable|null = null

Called when a named savepoint is created

Return values
bool

getTransactionDepth()

Get transaction depth

public getTransactionDepth() : int
Return values
int

isTransaction()

Check if adapter is in the middle of an open transaction

public isTransaction() : bool
Return values
bool

leave()

Leave a transaction or reduce nesting level

public leave(bool $doCommit[, callable|null $commitFunc = null ][, callable|null $rollbackFunc = null ][, callable|null $savepointReleaseFunc = null ][, callable|null $savepointRollbackFunc = null ]) : bool
Parameters
$doCommit : bool

If true, perform a commit. Rollback otherwise.

$commitFunc : callable|null = null

Called when a top-level commit must be performed

$rollbackFunc : callable|null = null

Called when a top-level rollback must be performed

$savepointReleaseFunc : callable|null = null

Called when a savepoint is released (like commit)

$savepointRollbackFunc : callable|null = null

Called when the transaction is rolled back to a savepoint

Return values
bool

        
On this page

Search results