Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'libs/Zend/Db/Profiler/Firebug.php')
-rw-r--r--libs/Zend/Db/Profiler/Firebug.php42
1 files changed, 21 insertions, 21 deletions
diff --git a/libs/Zend/Db/Profiler/Firebug.php b/libs/Zend/Db/Profiler/Firebug.php
index 35a4ebd7b9..0ffaf142be 100644
--- a/libs/Zend/Db/Profiler/Firebug.php
+++ b/libs/Zend/Db/Profiler/Firebug.php
@@ -15,27 +15,27 @@
* @category Zend
* @package Zend_Db
* @subpackage Profiler
- * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
+ * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
- * @version $Id: Firebug.php 16971 2009-07-22 18:05:45Z mikaelkael $
+ * @version $Id: Firebug.php 20096 2010-01-06 02:05:09Z bkarwin $
*/
/** Zend_Db_Profiler */
-require_once 'Zend/Db/Profiler.php';
+// require_once 'Zend/Db/Profiler.php';
/** Zend_Wildfire_Plugin_FirePhp */
-require_once 'Zend/Wildfire/Plugin/FirePhp.php';
+// require_once 'Zend/Wildfire/Plugin/FirePhp.php';
/** Zend_Wildfire_Plugin_FirePhp_TableMessage */
-require_once 'Zend/Wildfire/Plugin/FirePhp/TableMessage.php';
+// require_once 'Zend/Wildfire/Plugin/FirePhp/TableMessage.php';
/**
* Writes DB events as log messages to the Firebug Console via FirePHP.
- *
+ *
* @category Zend
* @package Zend_Db
* @subpackage Profiler
- * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
+ * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
class Zend_Db_Profiler_Firebug extends Zend_Db_Profiler
@@ -45,25 +45,25 @@ class Zend_Db_Profiler_Firebug extends Zend_Db_Profiler
* @var string
*/
protected $_label = null;
-
+
/**
* The label template for this profiler
* @var string
*/
protected $_label_template = '%label% (%totalCount% @ %totalDuration% sec)';
-
+
/**
* The message envelope holding the profiling summary
* @var Zend_Wildfire_Plugin_FirePhp_TableMessage
*/
protected $_message = null;
-
+
/**
* The total time taken for all profiled queries.
* @var float
*/
protected $_totalElapsedTime = 0;
-
+
/**
* Constructor
*
@@ -90,7 +90,7 @@ class Zend_Db_Profiler_Firebug extends Zend_Db_Profiler
parent::setEnabled($enable);
if ($this->getEnabled()) {
-
+
if (!$this->_message) {
$this->_message = new Zend_Wildfire_Plugin_FirePhp_TableMessage($this->_label);
$this->_message->setBuffered(true);
@@ -106,7 +106,7 @@ class Zend_Db_Profiler_Firebug extends Zend_Db_Profiler
$this->_message->setDestroy(true);
$this->_message = null;
}
-
+
}
return $this;
@@ -121,28 +121,28 @@ class Zend_Db_Profiler_Firebug extends Zend_Db_Profiler
*/
public function queryEnd($queryId)
{
- parent::queryEnd($queryId);
-
- if (!$this->getEnabled()) {
+ $state = parent::queryEnd($queryId);
+
+ if (!$this->getEnabled() || $state == self::IGNORED) {
return;
}
$this->_message->setDestroy(false);
$profile = $this->getQueryProfile($queryId);
-
+
$this->_totalElapsedTime += $profile->getElapsedSecs();
-
+
$this->_message->addRow(array((string)round($profile->getElapsedSecs(),5),
$profile->getQuery(),
($params=$profile->getQueryParams())?$params:null));
-
+
$this->updateMessageLabel();
}
-
+
/**
* Update the label of the message holding the profile info.
- *
+ *
* @return void
*/
protected function updateMessageLabel()