Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members

POMessageFactory.h

Go to the documentation of this file.
00001 #ifndef _POMESSAGEFACTORY_H_
00002 #define _POMESSAGEFACTORY_H_
00003 #include<string>
00004 #include<map>
00005 #include<POMessage.h>
00006 using namespace std;
00007 
00008 #ifdef WIN32
00009 #include <windows.h>
00010 #ifdef PEXPR_EXPORTS
00011 #define PEXPR_API __declspec(dllexport)
00012 #else
00013 #define PEXPR_API __declspec(dllimport)
00014 #endif /* PEXPR_EXPORTS */
00015 #else
00016 #define PEXPR_API
00017 #endif /* WIN32 */
00018 
00019 class PEXPR_API POMessageFactory
00020 {
00021     public:
00022         static void init();
00023         static bool Register( POMessage* msg );
00024         static bool UnRegister( const string& type );
00025 
00026         static POMessage* BuildFromBuffer( char* buffer );
00027         static POMessage* Build( const string& type );
00028 
00029     private:
00030         static map<string, POMessage*>  *m_messages;
00031         static bool                      m_init;
00032 };
00033 
00034 #endif

Generated on Tue Jun 15 12:49:28 2004 for pexpr by doxygen 1.3.4