packet.h
Go to the documentation of this file.
00001 
00031 #ifndef CREATE_PACKET_H
00032 #define CREATE_PACKET_H
00033 
00034 #include <boost/thread/mutex.hpp>
00035 
00036 namespace create {
00037   class Packet {
00038     private:
00039       uint16_t data;
00040       uint16_t tmpData;
00041       mutable boost::mutex dataMutex;
00042       mutable boost::mutex tmpDataMutex;
00043 
00044     protected:
00045       // Thread safe
00046       void setData(const uint16_t& d);
00047 
00048     public:
00049       const uint8_t nbytes;
00050       const std::string info;
00051 
00052       Packet(const uint8_t& nbytes, const std::string& info);
00053       ~Packet();
00054 
00055       // Thread safe
00056       void setDataToValidate(const uint16_t& td);
00057       // Thread safe
00058       void validate();
00059       // Thread safe
00060       uint16_t getData() const;
00061   };
00062 
00063 }  // namepsace create
00064 
00065 #endif // CREATE_PACKET_H


libcreate
Author(s): Jacob Perron
autogenerated on Thu Jun 6 2019 21:02:06