Exemplo n.º 1
0
 /**
  * Reset collected statistics for specified timer or for whole profiler if timer name is omitted
  *
  * @param string|null $timerName
  */
 public static function reset($timerName = null)
 {
     if ($timerName === null) {
         self::$_timers = array();
         self::$_currentPath = array();
         return;
     }
     $timerId = self::_getTimerId($timerName);
     self::$_timers[$timerId] = array('start' => false, self::FETCH_TIME => 0, self::FETCH_COUNT => 0, self::FETCH_REALMEM => 0, self::FETCH_EMALLOC => 0);
 }
Exemplo n.º 2
0
 /**
  * Reset profiler to initial state
  */
 public static function reset()
 {
     self::clear();
     self::$_enabled = false;
     self::$_currentPath = array();
     self::$_tagFilters = array();
     self::$_defaultTags = array();
     self::$_hasTagFilters = false;
     self::$_drivers = array();
     self::$_pathCount = 0;
     self::$_pathIndex = array();
 }