00001 #ifndef _ROS_household_objects_database_msgs_DatabaseModelPoseList_h 00002 #define _ROS_household_objects_database_msgs_DatabaseModelPoseList_h 00003 00004 #include <stdint.h> 00005 #include <string.h> 00006 #include <stdlib.h> 00007 #include "ros/msg.h" 00008 #include "household_objects_database_msgs/DatabaseModelPose.h" 00009 00010 namespace household_objects_database_msgs 00011 { 00012 00013 class DatabaseModelPoseList : public ros::Msg 00014 { 00015 public: 00016 uint8_t model_list_length; 00017 household_objects_database_msgs::DatabaseModelPose st_model_list; 00018 household_objects_database_msgs::DatabaseModelPose * model_list; 00019 00020 virtual int serialize(unsigned char *outbuffer) const 00021 { 00022 int offset = 0; 00023 *(outbuffer + offset++) = model_list_length; 00024 *(outbuffer + offset++) = 0; 00025 *(outbuffer + offset++) = 0; 00026 *(outbuffer + offset++) = 0; 00027 for( uint8_t i = 0; i < model_list_length; i++){ 00028 offset += this->model_list[i].serialize(outbuffer + offset); 00029 } 00030 return offset; 00031 } 00032 00033 virtual int deserialize(unsigned char *inbuffer) 00034 { 00035 int offset = 0; 00036 uint8_t model_list_lengthT = *(inbuffer + offset++); 00037 if(model_list_lengthT > model_list_length) 00038 this->model_list = (household_objects_database_msgs::DatabaseModelPose*)realloc(this->model_list, model_list_lengthT * sizeof(household_objects_database_msgs::DatabaseModelPose)); 00039 offset += 3; 00040 model_list_length = model_list_lengthT; 00041 for( uint8_t i = 0; i < model_list_length; i++){ 00042 offset += this->st_model_list.deserialize(inbuffer + offset); 00043 memcpy( &(this->model_list[i]), &(this->st_model_list), sizeof(household_objects_database_msgs::DatabaseModelPose)); 00044 } 00045 return offset; 00046 } 00047 00048 const char * getType(){ return "household_objects_database_msgs/DatabaseModelPoseList"; }; 00049 const char * getMD5(){ return "f0bb2aa8d2ededee0ffe0f5d2107e099"; }; 00050 00051 }; 00052 00053 } 00054 #endif