00001 #ifndef CONFIG_CONNECTION_H 00002 #define CONFIG_CONNECTION_H 00003 #include <string> 00004 #include <errno.h> 00005 #include <stdlib.h> 00006 #include <unistd.h> 00007 #include <sys/time.h> 00008 #include <sys/types.h> 00009 #include <sys/socket.h> 00010 #include <netinet/in.h> 00011 #include <netdb.h> 00012 #include "Connection.h" 00013 #include "Message.h" 00014 00015 00020 class ConfigConnection: public Connection<char> { 00021 public: 00026 ConfigConnection(BufferedFile * fd); 00030 bool isMessage(); 00035 void update(); 00039 Message * getMessage(); // Gets the current message on the message queue. 00043 int write(const char * data, int size); 00047 virtual ~ConfigConnection(); 00051 virtual bool readReady(); 00055 virtual bool writeReady(); 00059 int getFileHandle(); 00063 string getType(); 00067 void setType(string type); 00068 protected: 00069 char * buffer; //temp work space. 00070 }; 00071 #endif