File "Debug.php"
Full path: /www/ansys/qgis/008_shinmoji/messages/output/class/Debug.php
File size: 1.93 KiB (1978 bytes)
MIME-type: text/x-php
Charset: utf-8
<?php
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
// デバック関連
// クラス名: cDebug
// 備考 :
// 更新 : 2012/10/19 KMK-Teraoka
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
class Debug
{
private static $mode;
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
// 呼び出し元のMODEを継承する
// 関数名 : setMode
// 引数 : $mode 呼び出し元のMODE
// 戻り値 : なし
// 備考 :
// 更新 : 2012/10/18 KMK-Teraoka
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
public static function setMode($mode_)
{
self::$mode = $mode_;
}
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
// デバック出力 -変数-
// 関数名 : dPrint
// 引数 : * 可変長引数
// 戻り値 : なし
// 備考 :
// 更新 : 2012/10/18 KMK-Teraoka
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
public static function write()
{
if (self::$mode == 1)
{
print "<font color=\"#989898\">";
$argNum = func_num_args();
$argList = func_get_args();
for($iCount = 0; $iCount < $argNum; $iCount++)
{
if ($iCount > 0)
{
print ", ";
}
print $argList[$iCount];
}
print "</font>";
print "<br />";
}
}
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
// デバック出力 -配列-
// 関数名 : dPrint_r
// 引数 : * 可変長引数
// 戻り値 : なし
// 備考 :
// 更新 : 2012/10/18 KMK-Teraoka
//-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
public static function writes()
{
if (self::$mode == 1)
{
print "<font color=\"#989898\">";
$argNum = func_num_args();
$argList = func_get_args();
for($iCount = 0; $iCount < $argNum; $iCount++)
{
if ($iCount > 0)
{
print "<br />";
}
print "<pre style=\"display:inline\">";
print "[". ($iCount + 1). "]=>";
print_r($argList[$iCount]);
print "</pre>";
}
print "</font>";
print "<br />";
}
}
}
?>