Go to the documentation of this file.00001
00002 #ifndef INDUSTRIAL_MSGS_MESSAGE_TRISTATE_H
00003 #define INDUSTRIAL_MSGS_MESSAGE_TRISTATE_H
00004 #include <string>
00005 #include <vector>
00006 #include <map>
00007 #include <ostream>
00008 #include "ros/serialization.h"
00009 #include "ros/builtin_message_traits.h"
00010 #include "ros/message_operations.h"
00011 #include "ros/time.h"
00012
00013 #include "ros/macros.h"
00014
00015 #include "ros/assert.h"
00016
00017
00018 namespace industrial_msgs
00019 {
00020 template <class ContainerAllocator>
00021 struct TriState_ {
00022 typedef TriState_<ContainerAllocator> Type;
00023
00024 TriState_()
00025 : val(0)
00026 {
00027 }
00028
00029 TriState_(const ContainerAllocator& _alloc)
00030 : val(0)
00031 {
00032 }
00033
00034 typedef int8_t _val_type;
00035 int8_t val;
00036
00037 enum { UNKNOWN = -1 };
00038 enum { TRUE = 1 };
00039 enum { ON = 1 };
00040 enum { ENABLED = 1 };
00041 enum { HIGH = 1 };
00042 enum { CLOSED = 1 };
00043 enum { FALSE = 0 };
00044 enum { OFF = 0 };
00045 enum { DISABLED = 0 };
00046 enum { LOW = 0 };
00047 enum { OPEN = 0 };
00048
00049 typedef boost::shared_ptr< ::industrial_msgs::TriState_<ContainerAllocator> > Ptr;
00050 typedef boost::shared_ptr< ::industrial_msgs::TriState_<ContainerAllocator> const> ConstPtr;
00051 boost::shared_ptr<std::map<std::string, std::string> > __connection_header;
00052 };
00053 typedef ::industrial_msgs::TriState_<std::allocator<void> > TriState;
00054
00055 typedef boost::shared_ptr< ::industrial_msgs::TriState> TriStatePtr;
00056 typedef boost::shared_ptr< ::industrial_msgs::TriState const> TriStateConstPtr;
00057
00058
00059 template<typename ContainerAllocator>
00060 std::ostream& operator<<(std::ostream& s, const ::industrial_msgs::TriState_<ContainerAllocator> & v)
00061 {
00062 ros::message_operations::Printer< ::industrial_msgs::TriState_<ContainerAllocator> >::stream(s, "", v);
00063 return s;}
00064
00065 }
00066
00067 namespace ros
00068 {
00069 namespace message_traits
00070 {
00071 template<class ContainerAllocator> struct IsMessage< ::industrial_msgs::TriState_<ContainerAllocator> > : public TrueType {};
00072 template<class ContainerAllocator> struct IsMessage< ::industrial_msgs::TriState_<ContainerAllocator> const> : public TrueType {};
00073 template<class ContainerAllocator>
00074 struct MD5Sum< ::industrial_msgs::TriState_<ContainerAllocator> > {
00075 static const char* value()
00076 {
00077 return "deb03829f3c2d0f1b647fa38d7087952";
00078 }
00079
00080 static const char* value(const ::industrial_msgs::TriState_<ContainerAllocator> &) { return value(); }
00081 static const uint64_t static_value1 = 0xdeb03829f3c2d0f1ULL;
00082 static const uint64_t static_value2 = 0xb647fa38d7087952ULL;
00083 };
00084
00085 template<class ContainerAllocator>
00086 struct DataType< ::industrial_msgs::TriState_<ContainerAllocator> > {
00087 static const char* value()
00088 {
00089 return "industrial_msgs/TriState";
00090 }
00091
00092 static const char* value(const ::industrial_msgs::TriState_<ContainerAllocator> &) { return value(); }
00093 };
00094
00095 template<class ContainerAllocator>
00096 struct Definition< ::industrial_msgs::TriState_<ContainerAllocator> > {
00097 static const char* value()
00098 {
00099 return "# The tri-state captures boolean values with the additional state of unknown\n\
00100 \n\
00101 int8 val\n\
00102 \n\
00103 # enumerated values\n\
00104 \n\
00105 # Unknown or unavailable \n\
00106 int8 UNKNOWN=-1 \n\
00107 \n\
00108 # High state \n\
00109 int8 TRUE=1\n\
00110 int8 ON=1\n\
00111 int8 ENABLED=1\n\
00112 int8 HIGH=1\n\
00113 int8 CLOSED=1\n\
00114 \n\
00115 # Low state\n\
00116 int8 FALSE=0\n\
00117 int8 OFF=0\n\
00118 int8 DISABLED=0\n\
00119 int8 LOW=0\n\
00120 int8 OPEN=0\n\
00121 \n\
00122 \n\
00123 ";
00124 }
00125
00126 static const char* value(const ::industrial_msgs::TriState_<ContainerAllocator> &) { return value(); }
00127 };
00128
00129 template<class ContainerAllocator> struct IsFixedSize< ::industrial_msgs::TriState_<ContainerAllocator> > : public TrueType {};
00130 }
00131 }
00132
00133 namespace ros
00134 {
00135 namespace serialization
00136 {
00137
00138 template<class ContainerAllocator> struct Serializer< ::industrial_msgs::TriState_<ContainerAllocator> >
00139 {
00140 template<typename Stream, typename T> inline static void allInOne(Stream& stream, T m)
00141 {
00142 stream.next(m.val);
00143 }
00144
00145 ROS_DECLARE_ALLINONE_SERIALIZER;
00146 };
00147 }
00148 }
00149
00150 namespace ros
00151 {
00152 namespace message_operations
00153 {
00154
00155 template<class ContainerAllocator>
00156 struct Printer< ::industrial_msgs::TriState_<ContainerAllocator> >
00157 {
00158 template<typename Stream> static void stream(Stream& s, const std::string& indent, const ::industrial_msgs::TriState_<ContainerAllocator> & v)
00159 {
00160 s << indent << "val: ";
00161 Printer<int8_t>::stream(s, indent + " ", v.val);
00162 }
00163 };
00164
00165
00166 }
00167 }
00168
00169 #endif // INDUSTRIAL_MSGS_MESSAGE_TRISTATE_H
00170