1
0
mirror of https://github.com/dg/dibi.git synced 2025-10-24 19:26:10 +02:00

* update DibiVariableInterface

* some bugs fixed
This commit is contained in:
David Grudl
2007-11-12 07:33:23 +00:00
parent 89c53395c1
commit 46850aa588
15 changed files with 53 additions and 53 deletions

View File

@@ -53,17 +53,17 @@ final class DibiLogger extends NObject
/**
* Event handler (events: exception, connected, beforeQuery, afterQuery, begin, commit, rollback)
*
* @param DibiConnection
* @param string event name
* @param mixed
* @param mixed
* @return void
*/
public function handler($event, $connection, $arg)
public function handler($connection, $event, $arg)
{
if ($event === 'afterQuery' && $this->logQueries) {
$this->write(
"OK: " . dibi::$sql
. ($arg instanceof DibiResult ? ";\n-- rows: " . $arg->rowCount() : '')
. ($arg instanceof DibiResult ? ";\n-- rows: " . count($arg) : '')
. "\n-- takes: " . sprintf('%0.3f', dibi::$elapsedTime * 1000) . ' ms'
. "\n-- driver: " . $connection->getConfig('driver')
. "\n-- " . date('Y-m-d H:i:s')