Class EventLog

Description

Habari EventLog class

  • todo: Apply system error handling

Located in /system/classes/eventlog.php (line 9)

ArrayObject
   |
   --EventLog
Variable Summary
Method Summary
static array get ([ $paramarray = array()], array $paramarry)
static string get_module ([ $module = null], [integer $level = 2])
static object LogEntry log (string $message, [string $severity = 'info'], [string $type = 'default'], [string $module = null], [mixed $data = null])
static void register_type ([string $type = 'default'], [string $module = null])
static void unregister_type ([string $type = 'default'], [string $module = null])
void __get (string $name)
Variables
mixed $get_param_cache (line 11)
  • access: protected
Methods
static method get (line 119)

Returns a LogEntry or EventLog array based on supplied parameters.

By default,fetch as many entries as pagination allows and order them in a descending fashion based on timestamp.

  • return: An array of LogEntry objects, or a single LogEntry object, depending on request
  • todo: Cache query results.
  • access: public
static array get ([ $paramarray = array()], array $paramarry)
  • array $paramarry: An associated array of parameters, or a querystring
  • $paramarray
static method get_module (line 101)

Get the module in which the logged code was executed

  • return: The classname or .php module in which the log code was called.
  • access: public
static string get_module ([ $module = null], [integer $level = 2])
  • integer $level: How many backtrace calls to go back through the trace
  • $module
static method log (line 77)

Write an entry to the event log.

  • return: The inserted LogEntry object
  • access: public
static object LogEntry log (string $message, [string $severity = 'info'], [string $type = 'default'], [string $module = null], [mixed $data = null])
  • string $message: The message
  • string $severity: The severity
  • string $type: The type
  • string $module: The module
  • mixed $data: The data
static method register_type (line 41)

Adds a logging type to the lookup table

  • access: public
static void register_type ([string $type = 'default'], [string $module = null])
  • string $type: The type of the error
  • string $module: The module of the error
static method unregister_type (line 57)

Removes a logging type from the lookup table

  • access: public
static void unregister_type ([string $type = 'default'], [string $module = null])
  • string $type: The type of the error
  • string $module: The module of the error
__get (line 25)

Returns properties of a EventLog object.

This is the function that returns information about the set of log entries that was requested. This function should offer property names that are identical to properties of instances of the URL class. A call to EventLog::get() without parameters should return mostly the same property values as the global $url object for the request. The difference would occur when the data returned doesn't necessarily match the request, such as when several log entries are requested, but only one is available to return.

  • access: public
void __get (string $name)
  • string $name: The name of the property to return.

Inherited Methods

Inherited From ArrayObject (Internal Class)

constructor __construct ( $array )
append ( $value )
asort ( )
count ( )
exchangeArray ( $array )
getArrayCopy ( )
getFlags ( )
getIterator ( )
getIteratorClass ( )
ksort ( )
natcasesort ( )
natsort ( )
offsetExists ( $index )
offsetGet ( $index )
offsetSet ( $index, $newval )
offsetUnset ( $index )
setFlags ( $flags )
setIteratorClass ( $iteratorClass )
uasort ( $cmp_function )
uksort ( $cmp_function )
Class Constants

Inherited Constants

Inherited from ArrayObject (Internal Class)

ARRAY_AS_PROPS = 2
STD_PROP_LIST = 1

Documentation generated on Thu, 30 Oct 2008 20:31:10 +0100 by phpDocumentor 1.3.2