Source for file Log.php
Documentation is available at Log.php
* Logging Class of Single Thread Monitoring<br>
* @subpackage sThread_CORE
* @author JoungKyun.Kim <http://oops.org>
* @copyright (c) 2015 OOPS.ORG
* @link http://pear.oops.org/package/sThread
* @subpackage sThread_CORE
* @author JoungKyun.Kim <http://oops.org>
* @copyright (c) 2015 OOPS.ORG
* @link http://pear.oops.org/package/sThread
* <li>0 -> 실패한 로그만 저장</li>
* <li>-1 -> 로그 저장 안함</li>
// {{{ (void) sThread_Log::save ($key, $recv)
static function save ($key, $recv) {
$res = &Vari::$res->status[$key];
if ( self::$type != 1 && $res[1] === true )
if ( ! trim (self::$fname) )
$logdate = date ('Ymd H:i:s');
$logfile = self::$fname . '.' . $format;
$logdir = dirname ($logfile);
ePrint::dPrintf (Vari::DEBUG1, "Error: Can't write %n", $logfile);
$log = sprintf ("[%s] %s %s\n", $logdate, $res[0], $res[2]);
if ( $res[1] === false && $recv ) {
ePrint::echoi ($recv, 4);
|