Class XoopsLogger

Description

Collects information for a page request

Singelton: There can be only one instance of this class and it must be accessed through the instance() method!

records information about database queries, blocks, and execution time and can display it as HTML

Located in Program_Root/class/logger.php (line 46)


	
			
Variable Summary
array $blocks
array $extra
array $logend
array $logstart
array $queries
Method Summary
void addBlock (string $name, [bool $cached = false], int $cachetime)
void addExtra (string $name, int $cachetime)
void addQuery (string $sql, [string $error = null], [int $errno = null])
string dumpAll ()
string dumpBlocks ()
string dumpExtra ()
string dumpQueries ()
float dumpTime ([string $name = 'XOOPS'])
void startTime ([string $name = 'XOOPS'])
void stopTime ([string $name = 'XOOPS'])
Variables
array $blocks = array() (line 52)
array $extra = array() (line 53)
array $logend = array() (line 55)
array $logstart = array() (line 54)
array $queries = array() (line 51)
Methods
addBlock (line 122)

log display of a block

void addBlock (string $name, [bool $cached = false], int $cachetime)
  • string $name: name of the block
  • bool $cached: was the block cached?
  • int $cachetime: cachetime of the block
addExtra (line 133)

log extra information

void addExtra (string $name, int $cachetime)
  • string $name: name for the entry
  • int $cachetime: cachetime for the entry
addQuery (line 110)

log a database query

void addQuery (string $sql, [string $error = null], [int $errno = null])
  • string $sql: SQL string
  • string $error: error message (if any)
  • int $errno: error number (if any)
dumpAll (line 221)

get all logged information formatted in HTML tables

  • return: HTML output
string dumpAll ()
dumpBlocks (line 164)

get the logged blocks in a HTML table

  • return: HTML table with blocks
string dumpBlocks ()
dumpExtra (line 204)

get extra information in a HTML table

  • return: HTML table with extra information
string dumpExtra ()
dumpQueries (line 143)

get the logged queries in a HTML table

  • return: HTML table with queries
string dumpQueries ()
dumpTime (line 186)

get the current execution time of a timer

  • return: current execution time of the counter
float dumpTime ([string $name = 'XOOPS'])
  • string $name: name of the counter
instance (line 73)

get a reference to the only instance of this class

  • return: reference to the only instance
object XoopsLogger &instance ()
startTime (line 88)

start a timer

void startTime ([string $name = 'XOOPS'])
  • string $name: name of the timer
stopTime (line 98)

stop a timer

void stopTime ([string $name = 'XOOPS'])
  • string $name: name of the timer

Documention generated on Wed, 28 May 2003 23:24:38 +0900 by phpDocumentor 1.2.0rc2