public function get_agg_profiles() { $prof_tday = get_pie($server_cfg, $game_cfg); $prof_yday = get_pie($server_cfg, $game_cfg, "yesterday"); $prof_wday = get_pie($server_cfg, $game_cfg, "lastweek"); $ret = array("tday" => $prof_tday, "yday" => $prof_yday, "wday" => $prof_wday); return $ret; }
$period = "absolute"; } switch ($period) { case "day": $prof_path = sprintf($server_cfg["daily_profile"], $game_cfg["name"]); break; case "30min": $prof_path = sprintf($server_cfg["daily_upload_directory"], $game_cfg["name"]); break; case "absolute": break; default: echo "Unsupported period \\'{$period}\\' for get_pie()"; error_log("Unsupported period \\'{$period}\\' for get_pie()"); return null; } if ($period != "absolute") { // Find all aggregate profiles in dir and take the last $profile_list = glob("{$prof_path}/*all.xhprof"); if (empty($profile_list)) { echo "no profile in {$period} {$prof_path}/*.all.xhprof"; return null; } $profile = end($profile_list); } return get_top_functions($profile, $metrics, $how_many); } $test_mode = true; if (isset($test_mode) && $test_mode) { print_r(get_pie("fluid")); }
function get_direct_pie($profile) { return get_pie(null, null, null, null, null, null, $profile); }
public function devuelve_ruta() { $tipo_controller = new Tipo_controller(); $contenido_controller = new ContenidoController(); $standar_controller = new Standar_controller(); $datos_generales = $standar_controller->obtener_datos_generales(); if ($this->es_contenido() && $this->es_pagina()) { $contenido = $contenido_controller->get_contenido_by_slug($this->segmento[0]); if (file_exists(RUTA_PLANTILLA . '/paginas/pagina_' . $this->segmento[0] . '.php')) { get_cabecera($contenido, $datos_generales); require_once RUTA_PLANTILLA . '/paginas/pagina_' . $this->segmento[0] . '.php'; get_pie($datos_generales); } else { require_once RUTA_PLANTILLA . '/paginas/pagina.php'; } } else { if ($this->es_carga_ajax()) { require_once RUTA_PLANTILLA . '/paginas/' . $this->segmento[0]; } else { $contenido = new Contenido(); get_cabecera($contenido, $datos_generales); require_once RUTA_PLANTILLA . '/paginas/pagina_404.php'; get_pie($datos_generales); } } }