Increased buffer size

Dependencies:   BufferedSerial

Fork of ros_lib_kinetic by Gary Servin

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers TestRequestResult.h Source File

TestRequestResult.h

00001 #ifndef _ROS_actionlib_TestRequestResult_h
00002 #define _ROS_actionlib_TestRequestResult_h
00003 
00004 #include <stdint.h>
00005 #include <string.h>
00006 #include <stdlib.h>
00007 #include "ros/msg.h"
00008 
00009 namespace actionlib
00010 {
00011 
00012   class TestRequestResult : public ros::Msg
00013   {
00014     public:
00015       typedef int32_t _the_result_type;
00016       _the_result_type the_result;
00017       typedef bool _is_simple_server_type;
00018       _is_simple_server_type is_simple_server;
00019 
00020     TestRequestResult():
00021       the_result(0),
00022       is_simple_server(0)
00023     {
00024     }
00025 
00026     virtual int serialize(unsigned char *outbuffer) const
00027     {
00028       int offset = 0;
00029       union {
00030         int32_t real;
00031         uint32_t base;
00032       } u_the_result;
00033       u_the_result.real = this->the_result;
00034       *(outbuffer + offset + 0) = (u_the_result.base >> (8 * 0)) & 0xFF;
00035       *(outbuffer + offset + 1) = (u_the_result.base >> (8 * 1)) & 0xFF;
00036       *(outbuffer + offset + 2) = (u_the_result.base >> (8 * 2)) & 0xFF;
00037       *(outbuffer + offset + 3) = (u_the_result.base >> (8 * 3)) & 0xFF;
00038       offset += sizeof(this->the_result);
00039       union {
00040         bool real;
00041         uint8_t base;
00042       } u_is_simple_server;
00043       u_is_simple_server.real = this->is_simple_server;
00044       *(outbuffer + offset + 0) = (u_is_simple_server.base >> (8 * 0)) & 0xFF;
00045       offset += sizeof(this->is_simple_server);
00046       return offset;
00047     }
00048 
00049     virtual int deserialize(unsigned char *inbuffer)
00050     {
00051       int offset = 0;
00052       union {
00053         int32_t real;
00054         uint32_t base;
00055       } u_the_result;
00056       u_the_result.base = 0;
00057       u_the_result.base |= ((uint32_t) (*(inbuffer + offset + 0))) << (8 * 0);
00058       u_the_result.base |= ((uint32_t) (*(inbuffer + offset + 1))) << (8 * 1);
00059       u_the_result.base |= ((uint32_t) (*(inbuffer + offset + 2))) << (8 * 2);
00060       u_the_result.base |= ((uint32_t) (*(inbuffer + offset + 3))) << (8 * 3);
00061       this->the_result = u_the_result.real;
00062       offset += sizeof(this->the_result);
00063       union {
00064         bool real;
00065         uint8_t base;
00066       } u_is_simple_server;
00067       u_is_simple_server.base = 0;
00068       u_is_simple_server.base |= ((uint8_t) (*(inbuffer + offset + 0))) << (8 * 0);
00069       this->is_simple_server = u_is_simple_server.real;
00070       offset += sizeof(this->is_simple_server);
00071      return offset;
00072     }
00073 
00074     const char * getType(){ return "actionlib/TestRequestResult"; };
00075     const char * getMD5(){ return "61c2364524499c7c5017e2f3fce7ba06"; };
00076 
00077   };
00078 
00079 }
00080 #endif