types.hpp
Go to the documentation of this file.
00001 #ifndef TYPES_HPP
00002 #define TYPES_HPP
00003 
00004 #include <vector>
00005 #include <stdint.h>
00006 #include "msp_id.hpp"
00007 
00008 namespace msp {
00009 
00010 typedef unsigned int uint;
00011 
00015 typedef std::vector<uint8_t> ByteVector;
00016 
00017 
00020 
00021 struct Message {
00022     virtual ID id() const = 0;
00023 
00024     virtual ~Message() { }
00025 };
00026 
00027 // send to FC
00028 struct Request : public Message {
00029     virtual void decode(const ByteVector &data) = 0;
00030 };
00031 
00032 // received from FC
00033 struct Response : public Message {
00034     virtual ByteVector encode() const = 0;
00035 };
00036 
00037 } // namespace msp
00038 
00039 #endif // TYPES_HPP


msp
Author(s): Christian Rauch
autogenerated on Mon Oct 9 2017 03:02:14