My Project
 All Classes Files Functions Variables Enumerations Enumerator Friends Macros Pages
CcNetMsgHandler.h
1 #ifndef GCP_UTIL_CCNETMSGHANDLER_H
2 #define GCP_UTIL_CCNETMSGHANDLER_H
3 
11 #include "gcp/util/common/CcNetMsg.h"
12 #include "gcp/util/common/NetReadStr.h"
13 #include "gcp/util/common/NetSendStr.h"
14 
15 namespace gcp {
16  namespace util {
17 
18  class CcNetMsg;
19 
21  public:
22 
27 
31  virtual ~CcNetMsgHandler();
32 
36  void attachReadStream(int fd);
37 
41  void attachSendStream(int fd);
42 
47  gcp::util::NetSendStr::NetSendId send();
48 
53  gcp::util::NetSendStr::NetSendId
55 
60  gcp::util::NetSendStr::NetSendId send(int fd);
61 
65  gcp::util::NetSendStr::NetSendId
66  send(int fd, gcp::util::CcNetMsg* msg);
67 
72  gcp::util::NetReadStr::NetReadId read();
73 
78  gcp::util::NetReadStr::NetReadId read(int fd);
79 
84 
89 
90  private:
91 
92  gcp::util::CcNetMsg netMsg_;
95 
96  }; // End class CcNetMsgHandler
97 
98  } // End namespace util
99 } // End namespace gcp
100 
101 
102 
103 
104 #endif // End #ifndef GCP_UTIL_CCNETMSGHANDLER_H
Definition: NetSendStr.h:30
void attachSendStream(int fd)
Definition: CcNetMsgHandler.cc:46
gcp::util::CcNetMsg * getCcNetMsg()
Definition: CcNetMsgHandler.cc:160
Definition: CcNetMsg.h:22
gcp::util::NetSendStr::NetSendId send()
Definition: CcNetMsgHandler.cc:97
void packCcNetMsg(gcp::util::CcNetMsg *msg)
Definition: CcNetMsgHandler.cc:150
Definition: CcNetMsgHandler.h:20
virtual ~CcNetMsgHandler()
Definition: CcNetMsgHandler.cc:26
void attachReadStream(int fd)
Definition: CcNetMsgHandler.cc:38
CcNetMsgHandler()
Definition: CcNetMsgHandler.cc:14
gcp::util::NetReadStr::NetReadId read()
Definition: CcNetMsgHandler.cc:55
Definition: NetReadStr.h:30