Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

Event Class Reference

List of all members.

Public Member Functions

void set (Hierarchy hierarchy, Level level, char[] msg, char[] name)
override char[] toString ()
char[] getName ()
char[] getContent ()
Level getLevel ()
Hierarchy getHierarchy ()
long getTime ()
uint getEpochSeconds ()
ulong getEpochMilliSeconds ()
uint getMilliSeconds ()
Event append (char[] x)

Static Public Member Functions

 this ()
ulong getUptime ()

Public Attributes

package Scratch scratch

Private Attributes

char[] msg
char[] name
ulong time
Level level
Hierarchy hierarchy

Static Private Attributes

uint epochTime
ulong beginTime

Detailed Description

Contains all information about a logging event, and is passed around between methods once it has been determined that the invoking logger is enabled for output.

Note that Event instances are maintained in a freelist rather than being allocated each time, and they include a scratchpad area for Layout formatters to use.

Definition at line 83 of file Event.d.


Member Function Documentation

this  )  [inline, static]
 

Setup the timing information for later use. Note how much effort it takes to get epoch time in Win32 ...

Definition at line 161 of file Event.d.

References Exception, time, and version.

ulong getUptime  )  [inline, static]
 

Return the number of milliseconds since the executable was started.

Definition at line 220 of file Event.d.

References time, and version.

Referenced by set().

void set Hierarchy  hierarchy,
Level  level,
char[]  msg,
char[]  name
[inline]
 

Set the various attributes of this event.

Definition at line 246 of file Event.d.

References getUptime().

Referenced by LoggerInstance::append().

override char [] toString  )  [inline]
 

Return the message attached to this event.

Definition at line 278 of file Event.d.

Referenced by Layout::content().

char [] getName  )  [inline]
 

Return the name of the logger which produced this event

Definition at line 289 of file Event.d.

Referenced by DateLayout::header().

char [] getContent  )  [inline]
 

Return the scratch buffer for formatting. This is a thread safe place to format data within, without allocating any memory.

Definition at line 302 of file Event.d.

Level getLevel  )  [inline]
 

Return the logger level of this event.

Definition at line 313 of file Event.d.

Referenced by Layout::levelString().

Hierarchy getHierarchy  )  [inline]
 

Return the hierarchy where the event was produced from

Definition at line 324 of file Event.d.

long getTime  )  [inline]
 

Return the time this event was produced

Definition at line 335 of file Event.d.

References time.

Referenced by SimpleTimerLayout::header().

uint getEpochSeconds  )  [inline]
 

Return the number of seconds since Jan 1st 1970

Definition at line 346 of file Event.d.

References time.

Referenced by DateLayout::header().

ulong getEpochMilliSeconds  )  [inline]
 

Return the number of milliseconds since Jan 1st 1970

Definition at line 357 of file Event.d.

References time.

uint getMilliSeconds  )  [inline]
 

Isolate the millisecond portion of the event timestamp

Definition at line 368 of file Event.d.

References time.

Referenced by DateLayout::header().

Event append char[]  x  )  [inline]
 

Append some content to the scratch buffer. This is limited to the size of said buffer, and will not expand further.

Definition at line 380 of file Event.d.

Referenced by SimpleTimerLayout::header(), and SimpleLayout::header().


Member Data Documentation

package Scratch scratch
 

Definition at line 91 of file Event.d.

Referenced by LoggerInstance::append(), and DateLayout::header().

char [] msg [private]
 

Definition at line 92 of file Event.d.

char [] name [private]
 

Definition at line 92 of file Event.d.

ulong time [private]
 

Definition at line 94 of file Event.d.

Level level [private]
 

Definition at line 95 of file Event.d.

Hierarchy hierarchy [private]
 

Definition at line 96 of file Event.d.

uint epochTime [static, private]
 

Definition at line 98 of file Event.d.

ulong beginTime [static, private]
 

Definition at line 99 of file Event.d.


The documentation for this class was generated from the following file:
Generated on Sun Mar 6 00:31:08 2005 for Mango by doxygen 1.3.6