# Home    # nevrax.com   
Nevrax
Nevrax.org
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
Docs
 
Documentation  
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  

NLMISC::IDisplayer Class Reference

Displayer interface. More...

#include <displayer.h>

Inheritance diagram for NLMISC::IDisplayer:

NLMISC::CFileDisplayer NLMISC::CMemDisplayer NLMISC::CMsgBoxDisplayer NLMISC::CStdDisplayer NLMISC::CWindowDisplayer NLNET::CNetDisplayer List of all members.

Public Methods

 IDisplayer (const char *displayerName="")
 Constructor. More...

virtual ~IDisplayer ()
 Destructor. More...

void display (const TDisplayInfo &args, const char *message)
 Display the string where it does. More...


Public Attributes

std::string DisplayerName
 This is the idenfiant for a displayer, it is used to fond or remove a displayer. More...


Protected Methods

virtual void doDisplay (const TDisplayInfo &args, const char *message)=0
 Method to implement in the deriver. More...


Static Protected Methods

const char * logTypeToString (CLog::TLogType logType, bool longFormat=false)
 Convert log type to string. More...

const char * IDisplayer::dateToHumanString ()
 Convert the current date to human string. More...

const char * dateToHumanString (time_t date)
 Convert date to "2000/01/14 10:05:17" string. More...

const char * dateToComputerString (time_t date)
 Convert date to "784551148" string (time in second from 1975). More...

const char * HeaderString ()

Private Attributes

CMutex * _Mutex

Detailed Description

Displayer interface.

Used to specialize a displayer to display a string. How to log information (for debugging purpose) ?

Author:
Vianney Lecroart , Nevrax France
Date:
2000

Definition at line 65 of file displayer.h.


Constructor & Destructor Documentation

NLMISC::IDisplayer::IDisplayer const char *    displayerName = ""
 

Constructor.

Definition at line 104 of file displayer.cpp.

References _Mutex, CMutex, and DisplayerName.

Referenced by NLMISC::CMsgBoxDisplayer::CMsgBoxDisplayer, NLMISC::CStdDisplayer::CStdDisplayer, and NLMISC::CWindowDisplayer::CWindowDisplayer.

NLMISC::IDisplayer::~IDisplayer   [virtual]
 

Destructor.

Definition at line 110 of file displayer.cpp.

References _Mutex.


Member Function Documentation

const char * NLMISC::IDisplayer::dateToComputerString time_t    date [static, protected]
 

Convert date to "784551148" string (time in second from 1975).

Definition at line 89 of file displayer.cpp.

References NLMISC::smprintf.

const char * NLMISC::IDisplayer::dateToHumanString time_t    date [static, protected]
 

Convert date to "2000/01/14 10:05:17" string.

Definition at line 82 of file displayer.cpp.

Referenced by NLMISC::CMemDisplayer::doDisplay, NLMISC::CMsgBoxDisplayer::doDisplay, NLMISC::CFileDisplayer::doDisplay, and HeaderString.

void NLMISC::IDisplayer::display const TDisplayInfo   args,
const char *    message
 

Display the string where it does.

Definition at line 118 of file displayer.cpp.

References _Mutex, and doDisplay.

virtual void NLMISC::IDisplayer::doDisplay const TDisplayInfo   args,
const char *    message
[protected, pure virtual]
 

Method to implement in the deriver.

Implemented in NLMISC::CStdDisplayer.

Referenced by display.

const char * NLMISC::IDisplayer::HeaderString   [static, protected]
 

Definition at line 96 of file displayer.cpp.

References dateToHumanString, and NLMISC::smprintf.

Referenced by NLMISC::CMemDisplayer::doDisplay, and NLMISC::CFileDisplayer::doDisplay.

const char* NLMISC::IDisplayer::IDisplayer::dateToHumanString   [static, protected]
 

Convert the current date to human string.

const char * NLMISC::IDisplayer::logTypeToString CLog::TLogType    logType,
bool    longFormat = false
[static, protected]
 

Convert log type to string.

Definition at line 67 of file displayer.cpp.

References NLMISC::LogTypeToString.

Referenced by NLMISC::CWindowDisplayer::doDisplay, NLMISC::CMemDisplayer::doDisplay, NLMISC::CMsgBoxDisplayer::doDisplay, NLMISC::CFileDisplayer::doDisplay, and NLMISC::CStdDisplayer::doDisplay.


Member Data Documentation

CMutex* NLMISC::IDisplayer::_Mutex [private]
 

Definition at line 104 of file displayer.h.

Referenced by display, IDisplayer, and ~IDisplayer.

std::string NLMISC::IDisplayer::DisplayerName
 

This is the idenfiant for a displayer, it is used to fond or remove a displayer.

Definition at line 79 of file displayer.h.

Referenced by IDisplayer.


The documentation for this class was generated from the following files: