Private Method Details |
bsLogger_LazyInclude |
|
private void bsLogger_LazyInclude( )
|
| |
This is an attemt to keep Bs_Logger a independent as possable
If no Db is used I don't event try to include the Db-Packagethat may not be available anyway.
|
| Returns |
void |
|
log |
|
private void log( string $msg, string $msgType, int $phpLine, [ string $phpFunc, string $phpFile, string $test ] )
|
| |
The log call
|
| Parameter |
|
| string |
$msg |
|
|
Keep it short. DB will take max 255 char. |
|
|
| string |
$msgType |
|
|
Your free to set what you want, eg ERROR or WARNING or ... |
|
|
| int |
$phpLine |
|
|
The __LINE__ |
|
|
| string |
$phpFunc |
= >>'-?-'<< |
|
The function name (use __FUNCTION__ with PHP 4.3.0) |
|
|
| string |
$phpFile |
= >>'-?-'<< |
|
The __FILE__ (only basename will be stored) |
|
|
| string |
$test |
= >>FALSE<< |
|
(optional) Default is FALSE. If TRUE will not log; will only set the 'hit' hash. |
|
| Returns |
void |
|
getTargetStatus |
|
private mixed getTargetStatus( [ string $targetKey ] )
|
| |
Get the status of the target 'db' or 'dir'. If TURE target seams OK
If FALSE then target had an error on init or is not used.
|
| Parameter |
|
| string |
$targetKey |
= >>NULL<< |
|
'db' or 'dir' (optional if not set, returns hash) |
|
| Returns |
mixed bool or hash with bool value for the targets. |
|
setDb |
|
private bool setDb( &$dsn )
|
| |
Init the Logger with the DB to write the log-info.
|
| Parameter |
|
|
&$dsn |
|
|
Warning: documentation is missing. |
|
| Returns |
bool TRUE if OK FALSE on error. |
| See Also |
getError() |
|
setDir |
|
private bool setDir( string $logDir )
|
| |
Init the Logger with the dir to write the log-files.
|
| Parameter |
|
| string |
$logDir |
|
|
full path (no file) to the log-dir. |
|
| Returns |
bool TRUE if OK FALSE on error. |
| See Also |
getError() |
|
getError |
|
private void getError( )
|
| |
Get last error
|
| Returns |
void |
|
createLogTable |
|
private void createLogTable( [ string $tblName ] )
|
| |
Creates the table for the log entries
Connection to the DB must be OK (see setDb).A 'CREATE TABLE IF NOT EXISTS' will be used.NOTE: The table name must end with 'Log'. It will otherwise be appended.
|
| Parameter |
|
| string |
$tblName |
= >>''<< |
|
The table name to create. *Must* end with 'Log' |
|
| Returns |
void |
| See Also |
setDb() |
|
dropLogTable |
|
private void dropLogTable( [ string $tblName ] )
|
| |
Drops the table for the log entries
Connection to the DB must be OK (see setDb).A 'DROP TABLE IF EXISTS' will be used.NOTE: The table name must end with 'Log'. It will otherwise be appended.
|
| Parameter |
|
| string |
$tblName |
= >>''<< |
|
The table name to drop. *Must* end with 'Log' |
|
| Returns |
void |
| See Also |
setDb() |
|
test |
|
private void test( $msg, $msgType, $phpLine, $phpFunc, $phpFile, $logProperty )
|
| |
|
| Parameter |
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msgType |
|
|
Warning: documentation is missing. |
|
|
|
$phpLine |
|
|
Warning: documentation is missing. |
|
|
|
$phpFunc |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$logProperty |
|
|
Warning: documentation is missing. |
|
| Returns |
void |
|
name |
|
private void name( $phpFile, $phpFile, $phpFile, $phpFile, $phpFile, $phpFile, $phpFile, $test, $test, $test, $test, $test, $test, $test, $test, $test, $test, $test, $test, $test, $test, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msg, $msgType, $phpLine, string $phpFunc, string $phpFile, string $test )
|
| |
Warning: documentation is missing.
|
| Parameter |
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$phpFile |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$test |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msg |
|
|
Warning: documentation is missing. |
|
|
|
$msgType |
|
|
Warning: documentation is missing. |
|
|
|
$phpLine |
|
|
Warning: documentation is missing. |
|
|
| string |
$phpFunc |
|
|
Warning: documentation is missing. |
|
|
| string |
$phpFile |
|
|
Warning: documentation is missing. |
|
|
| string |
$test |
|
|
Warning: documentation is missing. |
|
| Returns |
void |
|