當前位置: 首頁>>代碼示例>>PHP>>正文


PHP debug::parse_cli_console方法代碼示例

本文整理匯總了PHP中debug::parse_cli_console方法的典型用法代碼示例。如果您正苦於以下問題:PHP debug::parse_cli_console方法的具體用法?PHP debug::parse_cli_console怎麽用?PHP debug::parse_cli_console使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在debug的用法示例。


在下文中一共展示了debug::parse_cli_console方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: _displayBrowse

 function _displayBrowse($path, &$root_group, &$current_group)
 {
     if (is_a($current_group, 'LimbGroupTest')) {
         $group_tests = $current_group->getTestCasesHandles();
     } else {
         $group_tests = array();
     }
     $buffer = "Available test cases in \n'=== " . $current_group->getLabel() . " ===' :\n";
     if (sizeof($group_tests)) {
         foreach ($group_tests as $index => $group_test) {
             resolve_handle($group_test);
             $buffer .= $path . '/' . $index . ' ' . $group_test->getLabel() . "\n";
         }
         $buffer .= "\n";
     } else {
         $buffer .= "No tests available.\n";
     }
     echo $buffer;
     echo debug::parse_cli_console();
 }
開發者ID:BackupTheBerlios,項目名稱:limb-svn,代碼行數:20,代碼來源:cli_test_runner.class.php

示例2: parse_console

 function parse_console()
 {
     if (sys::exec_mode() == 'cli') {
         return debug::parse_cli_console();
     } else {
         return debug::parse_html_console();
     }
 }
開發者ID:BackupTheBerlios,項目名稱:limb-svn,代碼行數:8,代碼來源:debug.class.php

示例3: nonbuffered_response

<?php

/**********************************************************************************
* Copyright 2004 BIT, Ltd. http://www.0x00.ru, mailto: bit@0x00.ru
*
* Released under the LGPL license (http://www.gnu.org/copyleft/lesser.html)
***********************************************************************************
*
* $Id$
*
***********************************************************************************/
$site_path = $argv[1];
require_once $site_path . '/setup.php';
require_once LIMB_DIR . '/core/lib/debug/debug.class.php';
require_once LIMB_DIR . '/core/request/nonbuffered_response.class.php';
require_once LIMB_DIR . '/core/lib/cron/cron_manager.class.php';
$force = false;
if (isset($argv[2]) && $argv[2] == 'force') {
    $force = true;
}
$response =& new nonbuffered_response();
$mgr =& new cron_manager();
$mgr->perform($response, $force);
$response->write(debug::parse_cli_console());
$response->commit();
exit(0);
開發者ID:BackupTheBerlios,項目名稱:limb-svn,代碼行數:26,代碼來源:cron.php

示例4: explode

    $script_settings = explode(';', $script_string);
    if (sizeof($script_settings) > 1) {
        $script_run_interval = (int) $script_settings[1];
    } else {
        $script_run_interval = 3600;
    }
    $script_name = $script_settings[0];
    $script_file = $cron_scripts_dir . $script_name;
    $now = time();
    if (file_exists($script_file)) {
        $time_diff = $now - (int) $scripts_last_run[$id];
        if ($time_diff > $script_run_interval) {
            echo "running {$script_name}\n";
            debug::add_timing_point("script {$script_name} starting\n");
            include $script_file;
            debug::add_timing_point("script done\n");
            $scripts_last_run[$id] = $now;
        } else {
            echo "will run {$script_name} in " . ($script_run_interval - $time_diff) . " seconds\n";
        }
    } else {
        echo "{$script_file} not found\n";
    }
}
$fp = fopen($cron_last_run_file, 'w');
foreach ($scripts_last_run as $time) {
    fwrite($fp, "{$time}\n");
}
fclose($fp);
echo debug::parse_cli_console();
ob_end_flush();
開發者ID:BackupTheBerlios,項目名稱:limb-svn,代碼行數:31,代碼來源:cron.php


注:本文中的debug::parse_cli_console方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。