Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

messageVI.h

Go to the documentation of this file.
00001 
00002 #ifndef messageVI_h
00003 #define messageVI_h
00004 
00005 #include "Event/nameVI.h"
00006 #include "Event/messageBase.h"
00007 
00008 //------------------------------------
00010 /*! 
00011 <ul>
00012         <li> The method \c message() allows the derived class to send messages (either strings, or 
00013         string + double values) to the messageManager.
00014         <li> It defines a LEVEL (from messageBase) indicating which is the level of
00015         information provided by the derived class. The \c acceptLevel() indicates when
00016         the level of the class is superior to the level of the messageManager.
00017         <li> The virtual method \c writeOut() is the place where the derived class should
00018         put the information that wants to write out. this method could/should be overwriten
00019         by the User.
00020         <li> The method \c setName() set the derived object into the server of messageManager,
00021         the object will be refered with its name. 
00022 </ul>
00023 */
00024 //-----------------------------------
00025 // JA Hernando, Santa Cruz, CA, 05/15/00
00026 //-----------------------------------
00027 //########################
00028 class messageVI : public nameVI
00029 //########################
00030 {
00031         friend class messageManager;
00032 
00033 public:
00034 
00036 
00037         bool acceptLevel() const;
00038         
00040         virtual void writeOut() const;
00041 
00042 protected:
00043 
00045         messageVI() {m_level = messageBase::DEBUG_HIGH;};
00047         virtual ~messageVI() {}
00048 
00050         virtual void setName(std::string name);
00051 
00053         void setLevel(std::string lev) { m_level = messageBase::getLevel(lev);};
00055         
00057         virtual void message(std::string message, std::string slevel = "") const ;
00059         virtual void message(std::string message, double value, std::string slevel = "") const;
00060 
00062         enum messageBase::LEVEL getLevel() const {return m_level;}
00063 
00064 private:
00065 
00067         enum messageBase::LEVEL m_level;
00068 
00069 };
00070 #endif

Generated at Fri Aug 18 12:57:38 2000 for centella framework by doxygen 1.1.3 written by Dimitri van Heesch, © 1997-2000