00001 #warning("This header has been deprecated in favor of rosgraph_msgs/Clock.h")
00002
00003
00004 #ifndef ROSLIB_MESSAGE_CLOCK_H
00005 #define ROSLIB_MESSAGE_CLOCK_H
00006 #include <string>
00007 #include <vector>
00008 #include <ostream>
00009 #include "ros/serialization.h"
00010 #include "ros/builtin_message_traits.h"
00011 #include "ros/message_operations.h"
00012 #include "ros/message.h"
00013 #include "ros/time.h"
00014
00015
00016 namespace roslib
00017 {
00018 template <class ContainerAllocator>
00019 struct Clock_ : public ros::Message
00020 {
00021 typedef Clock_<ContainerAllocator> Type;
00022
00023 Clock_()
00024 : clock()
00025 {
00026 }
00027
00028 Clock_(const ContainerAllocator& _alloc)
00029 : clock()
00030 {
00031 }
00032
00033 typedef ros::Time _clock_type;
00034 ros::Time clock;
00035
00036
00037 private:
00038 static const char* __s_getDataType_() { return "roslib/Clock"; }
00039 public:
00040 static const std::string __s_getDataType() { return __s_getDataType_(); }
00041
00042 const std::string __getDataType() const { return __s_getDataType_(); }
00043
00044 private:
00045 static const char* __s_getMD5Sum_() { return "a9c97c1d230cfc112e270351a944ee47"; }
00046 public:
00047 static const std::string __s_getMD5Sum() { return __s_getMD5Sum_(); }
00048
00049 const std::string __getMD5Sum() const { return __s_getMD5Sum_(); }
00050
00051 private:
00052 static const char* __s_getMessageDefinition_() { return "# roslib/Clock is used for publishing simulated time in ROS. \n\
00053 # This message simply communicates the current time.\n\
00054 # For more information, see http://www.ros.org/wiki/Clock\n\
00055 time clock\n\
00056 \n\
00057 "; }
00058 public:
00059 static const std::string __s_getMessageDefinition() { return __s_getMessageDefinition_(); }
00060
00061 const std::string __getMessageDefinition() const { return __s_getMessageDefinition_(); }
00062
00063 virtual uint8_t *serialize(uint8_t *write_ptr, uint32_t seq) const
00064 {
00065 ros::serialization::OStream stream(write_ptr, 1000000000);
00066 ros::serialization::serialize(stream, clock);
00067 return stream.getData();
00068 }
00069
00070 virtual uint8_t *deserialize(uint8_t *read_ptr)
00071 {
00072 ros::serialization::IStream stream(read_ptr, 1000000000);
00073 ros::serialization::deserialize(stream, clock);
00074 return stream.getData();
00075 }
00076
00077 virtual uint32_t serializationLength() const
00078 {
00079 uint32_t size = 0;
00080 size += ros::serialization::serializationLength(clock);
00081 return size;
00082 }
00083
00084 typedef boost::shared_ptr< ::roslib::Clock_<ContainerAllocator> > Ptr;
00085 typedef boost::shared_ptr< ::roslib::Clock_<ContainerAllocator> const> ConstPtr;
00086 };
00087 typedef ::roslib::Clock_<std::allocator<void> > Clock;
00088
00089 typedef boost::shared_ptr< ::roslib::Clock> ClockPtr;
00090 typedef boost::shared_ptr< ::roslib::Clock const> ClockConstPtr;
00091
00092
00093 template<typename ContainerAllocator>
00094 std::ostream& operator<<(std::ostream& s, const ::roslib::Clock_<ContainerAllocator> & v)
00095 {
00096 ros::message_operations::Printer< ::roslib::Clock_<ContainerAllocator> >::stream(s, "", v);
00097 return s;}
00098
00099 }
00100
00101 namespace ros
00102 {
00103 namespace message_traits
00104 {
00105 template<class ContainerAllocator>
00106 struct MD5Sum< ::roslib::Clock_<ContainerAllocator> > {
00107 static const char* value()
00108 {
00109 return "a9c97c1d230cfc112e270351a944ee47";
00110 }
00111
00112 static const char* value(const ::roslib::Clock_<ContainerAllocator> &) { return value(); }
00113 static const uint64_t static_value1 = 0xa9c97c1d230cfc11ULL;
00114 static const uint64_t static_value2 = 0x2e270351a944ee47ULL;
00115 };
00116
00117 template<class ContainerAllocator>
00118 struct DataType< ::roslib::Clock_<ContainerAllocator> > {
00119 static const char* value()
00120 {
00121 return "roslib/Clock";
00122 }
00123
00124 static const char* value(const ::roslib::Clock_<ContainerAllocator> &) { return value(); }
00125 };
00126
00127 template<class ContainerAllocator>
00128 struct Definition< ::roslib::Clock_<ContainerAllocator> > {
00129 static const char* value()
00130 {
00131 return "# roslib/Clock is used for publishing simulated time in ROS. \n\
00132 # This message simply communicates the current time.\n\
00133 # For more information, see http://www.ros.org/wiki/Clock\n\
00134 time clock\n\
00135 \n\
00136 ";
00137 }
00138
00139 static const char* value(const ::roslib::Clock_<ContainerAllocator> &) { return value(); }
00140 };
00141
00142 template<class ContainerAllocator> struct IsFixedSize< ::roslib::Clock_<ContainerAllocator> > : public TrueType {};
00143 }
00144 }
00145
00146 namespace ros
00147 {
00148 namespace serialization
00149 {
00150
00151 template<class ContainerAllocator> struct Serializer< ::roslib::Clock_<ContainerAllocator> >
00152 {
00153 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00154 {
00155 stream.next(m.clock);
00156 }
00157
00158 ROS_DECLARE_ALLINONE_SERIALIZER;
00159 };
00160 }
00161 }
00162
00163 namespace ros
00164 {
00165 namespace message_operations
00166 {
00167
00168 template<class ContainerAllocator>
00169 struct Printer< ::roslib::Clock_<ContainerAllocator> >
00170 {
00171 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::roslib::Clock_<ContainerAllocator> & v)
00172 {
00173 s << indent << "clock: ";
00174 Printer<ros::Time>::stream(s, indent + " ", v.clock);
00175 }
00176 };
00177
00178
00179 }
00180 }
00181
00182 #endif // ROSLIB_MESSAGE_CLOCK_H
00183