This interface defines the methods you can depend on in a connection.
config( )
Get the configuration data used to create the connection.
arrayconfigName( )
Get the configuration name for this connection.
stringdisableConstraints( callable $operation )
Run an operation with constraints disabled.
Constraints should be re-enabled after the callback succeeds/fails.
$operation mixedExceptionlogQueries( boolean $enable null )
Enables or disables query logging for this connection.
$enable optional null booleanlogger( object $instance null )
Sets the logger object instance. When called with no arguments it returns the currently setup logger instance.
$instance optional null objecttransactional( callable $transaction )
Executes a callable function inside a transaction, if any exception occurs while executing the passed callable, the transaction will be rolled back If the result of the callable function is false, the transaction will also be rolled back. Otherwise the transaction is committed after executing the callback.
The callback will receive the connection instance as its first argument.
$transaction mixedException
© 2005–2016 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
http://api.cakephp.org/3.1/class-Cake.Datasource.ConnectionInterface.html