Personal fork
Fork of rosserial_mbed_lib by
nav_msgs/GetMap.h@5:19c5437ed9fe, 2014-05-01 (annotated)
- Committer:
- garyservin
- Date:
- Thu May 01 06:01:31 2014 +0000
- Revision:
- 5:19c5437ed9fe
- Parent:
- 4:684f39d0c346
Updated to hydro
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
nucho | 3:1cf99502f396 | 1 | #ifndef _ROS_SERVICE_GetMap_h |
nucho | 3:1cf99502f396 | 2 | #define _ROS_SERVICE_GetMap_h |
nucho | 0:77afd7560544 | 3 | #include <stdint.h> |
nucho | 0:77afd7560544 | 4 | #include <string.h> |
nucho | 0:77afd7560544 | 5 | #include <stdlib.h> |
nucho | 3:1cf99502f396 | 6 | #include "ros/msg.h" |
nucho | 0:77afd7560544 | 7 | #include "nav_msgs/OccupancyGrid.h" |
nucho | 0:77afd7560544 | 8 | |
nucho | 0:77afd7560544 | 9 | namespace nav_msgs |
nucho | 0:77afd7560544 | 10 | { |
nucho | 0:77afd7560544 | 11 | |
nucho | 0:77afd7560544 | 12 | static const char GETMAP[] = "nav_msgs/GetMap"; |
nucho | 0:77afd7560544 | 13 | |
nucho | 0:77afd7560544 | 14 | class GetMapRequest : public ros::Msg |
nucho | 0:77afd7560544 | 15 | { |
nucho | 0:77afd7560544 | 16 | public: |
nucho | 0:77afd7560544 | 17 | |
nucho | 3:1cf99502f396 | 18 | virtual int serialize(unsigned char *outbuffer) const |
nucho | 0:77afd7560544 | 19 | { |
nucho | 0:77afd7560544 | 20 | int offset = 0; |
nucho | 0:77afd7560544 | 21 | return offset; |
nucho | 0:77afd7560544 | 22 | } |
nucho | 0:77afd7560544 | 23 | |
nucho | 0:77afd7560544 | 24 | virtual int deserialize(unsigned char *inbuffer) |
nucho | 0:77afd7560544 | 25 | { |
nucho | 0:77afd7560544 | 26 | int offset = 0; |
nucho | 0:77afd7560544 | 27 | return offset; |
nucho | 0:77afd7560544 | 28 | } |
nucho | 0:77afd7560544 | 29 | |
nucho | 4:684f39d0c346 | 30 | const char * getType(){ return GETMAP; }; |
nucho | 4:684f39d0c346 | 31 | const char * getMD5(){ return "d41d8cd98f00b204e9800998ecf8427e"; }; |
nucho | 0:77afd7560544 | 32 | |
nucho | 0:77afd7560544 | 33 | }; |
nucho | 0:77afd7560544 | 34 | |
nucho | 0:77afd7560544 | 35 | class GetMapResponse : public ros::Msg |
nucho | 0:77afd7560544 | 36 | { |
nucho | 0:77afd7560544 | 37 | public: |
nucho | 0:77afd7560544 | 38 | nav_msgs::OccupancyGrid map; |
nucho | 0:77afd7560544 | 39 | |
nucho | 3:1cf99502f396 | 40 | virtual int serialize(unsigned char *outbuffer) const |
nucho | 0:77afd7560544 | 41 | { |
nucho | 0:77afd7560544 | 42 | int offset = 0; |
nucho | 0:77afd7560544 | 43 | offset += this->map.serialize(outbuffer + offset); |
nucho | 0:77afd7560544 | 44 | return offset; |
nucho | 0:77afd7560544 | 45 | } |
nucho | 0:77afd7560544 | 46 | |
nucho | 0:77afd7560544 | 47 | virtual int deserialize(unsigned char *inbuffer) |
nucho | 0:77afd7560544 | 48 | { |
nucho | 0:77afd7560544 | 49 | int offset = 0; |
nucho | 0:77afd7560544 | 50 | offset += this->map.deserialize(inbuffer + offset); |
nucho | 0:77afd7560544 | 51 | return offset; |
nucho | 0:77afd7560544 | 52 | } |
nucho | 0:77afd7560544 | 53 | |
nucho | 4:684f39d0c346 | 54 | const char * getType(){ return GETMAP; }; |
nucho | 4:684f39d0c346 | 55 | const char * getMD5(){ return "6cdd0a18e0aff5b0a3ca2326a89b54ff"; }; |
nucho | 3:1cf99502f396 | 56 | |
nucho | 3:1cf99502f396 | 57 | }; |
nucho | 0:77afd7560544 | 58 | |
nucho | 3:1cf99502f396 | 59 | class GetMap { |
nucho | 3:1cf99502f396 | 60 | public: |
nucho | 3:1cf99502f396 | 61 | typedef GetMapRequest Request; |
nucho | 3:1cf99502f396 | 62 | typedef GetMapResponse Response; |
nucho | 0:77afd7560544 | 63 | }; |
nucho | 0:77afd7560544 | 64 | |
nucho | 0:77afd7560544 | 65 | } |
nucho | 0:77afd7560544 | 66 | #endif |