00001 """autogenerated by genmsg_py from UDPMultGetTopicListRequest.msg. Do not edit."""
00002 import roslib.message
00003 import struct
00004
00005
00006 class UDPMultGetTopicListRequest(roslib.message.Message):
00007 _md5sum = "d41d8cd98f00b204e9800998ecf8427e"
00008 _type = "udpmulti_transport/UDPMultGetTopicListRequest"
00009 _has_header = False
00010 _full_text = """
00011 """
00012 __slots__ = []
00013 _slot_types = []
00014
00015 def __init__(self, *args, **kwds):
00016 """
00017 Constructor. Any message fields that are implicitly/explicitly
00018 set to None will be assigned a default value. The recommend
00019 use is keyword arguments as this is more robust to future message
00020 changes. You cannot mix in-order arguments and keyword arguments.
00021
00022 The available fields are:
00023
00024
00025 @param args: complete set of field values, in .msg order
00026 @param kwds: use keyword arguments corresponding to message field names
00027 to set specific fields.
00028 """
00029 if args or kwds:
00030 super(UDPMultGetTopicListRequest, self).__init__(*args, **kwds)
00031
00032 def _get_types(self):
00033 """
00034 internal API method
00035 """
00036 return self._slot_types
00037
00038 def serialize(self, buff):
00039 """
00040 serialize message into buffer
00041 @param buff: buffer
00042 @type buff: StringIO
00043 """
00044 try:
00045 pass
00046 except struct.error, se: self._check_types(se)
00047 except TypeError, te: self._check_types(te)
00048
00049 def deserialize(self, str):
00050 """
00051 unpack serialized message in str into this message instance
00052 @param str: byte array of serialized message
00053 @type str: str
00054 """
00055 try:
00056 end = 0
00057 return self
00058 except struct.error, e:
00059 raise roslib.message.DeserializationError(e)
00060
00061
00062 def serialize_numpy(self, buff, numpy):
00063 """
00064 serialize message with numpy array types into buffer
00065 @param buff: buffer
00066 @type buff: StringIO
00067 @param numpy: numpy python module
00068 @type numpy module
00069 """
00070 try:
00071 pass
00072 except struct.error, se: self._check_types(se)
00073 except TypeError, te: self._check_types(te)
00074
00075 def deserialize_numpy(self, str, numpy):
00076 """
00077 unpack serialized message in str into this message instance using numpy for array types
00078 @param str: byte array of serialized message
00079 @type str: str
00080 @param numpy: numpy python module
00081 @type numpy: module
00082 """
00083 try:
00084 end = 0
00085 return self
00086 except struct.error, e:
00087 raise roslib.message.DeserializationError(e)
00088
00089 _struct_I = roslib.message.struct_I
00090 """autogenerated by genmsg_py from UDPMultGetTopicListResponse.msg. Do not edit."""
00091 import roslib.message
00092 import struct
00093
00094 import udpmulti_transport.msg
00095
00096 class UDPMultGetTopicListResponse(roslib.message.Message):
00097 _md5sum = "22672cb98b49fe101a321cb17bceec21"
00098 _type = "udpmulti_transport/UDPMultGetTopicListResponse"
00099 _has_header = False
00100 _full_text = """string multicast_address
00101 udpmulti_transport/UDPMultTopic[] topics
00102
00103
00104 ================================================================================
00105 MSG: udpmulti_transport/UDPMultTopic
00106 string topic
00107 uint16 port
00108
00109 """
00110 __slots__ = ['multicast_address','topics']
00111 _slot_types = ['string','udpmulti_transport/UDPMultTopic[]']
00112
00113 def __init__(self, *args, **kwds):
00114 """
00115 Constructor. Any message fields that are implicitly/explicitly
00116 set to None will be assigned a default value. The recommend
00117 use is keyword arguments as this is more robust to future message
00118 changes. You cannot mix in-order arguments and keyword arguments.
00119
00120 The available fields are:
00121 multicast_address,topics
00122
00123 @param args: complete set of field values, in .msg order
00124 @param kwds: use keyword arguments corresponding to message field names
00125 to set specific fields.
00126 """
00127 if args or kwds:
00128 super(UDPMultGetTopicListResponse, self).__init__(*args, **kwds)
00129
00130 if self.multicast_address is None:
00131 self.multicast_address = ''
00132 if self.topics is None:
00133 self.topics = []
00134 else:
00135 self.multicast_address = ''
00136 self.topics = []
00137
00138 def _get_types(self):
00139 """
00140 internal API method
00141 """
00142 return self._slot_types
00143
00144 def serialize(self, buff):
00145 """
00146 serialize message into buffer
00147 @param buff: buffer
00148 @type buff: StringIO
00149 """
00150 try:
00151 _x = self.multicast_address
00152 length = len(_x)
00153 buff.write(struct.pack('<I%ss'%length, length, _x))
00154 length = len(self.topics)
00155 buff.write(_struct_I.pack(length))
00156 for val1 in self.topics:
00157 _x = val1.topic
00158 length = len(_x)
00159 buff.write(struct.pack('<I%ss'%length, length, _x))
00160 buff.write(_struct_H.pack(val1.port))
00161 except struct.error, se: self._check_types(se)
00162 except TypeError, te: self._check_types(te)
00163
00164 def deserialize(self, str):
00165 """
00166 unpack serialized message in str into this message instance
00167 @param str: byte array of serialized message
00168 @type str: str
00169 """
00170 try:
00171 end = 0
00172 start = end
00173 end += 4
00174 (length,) = _struct_I.unpack(str[start:end])
00175 start = end
00176 end += length
00177 self.multicast_address = str[start:end]
00178 start = end
00179 end += 4
00180 (length,) = _struct_I.unpack(str[start:end])
00181 self.topics = []
00182 for i in xrange(0, length):
00183 val1 = udpmulti_transport.msg.UDPMultTopic()
00184 start = end
00185 end += 4
00186 (length,) = _struct_I.unpack(str[start:end])
00187 start = end
00188 end += length
00189 val1.topic = str[start:end]
00190 start = end
00191 end += 2
00192 (val1.port,) = _struct_H.unpack(str[start:end])
00193 self.topics.append(val1)
00194 return self
00195 except struct.error, e:
00196 raise roslib.message.DeserializationError(e)
00197
00198
00199 def serialize_numpy(self, buff, numpy):
00200 """
00201 serialize message with numpy array types into buffer
00202 @param buff: buffer
00203 @type buff: StringIO
00204 @param numpy: numpy python module
00205 @type numpy module
00206 """
00207 try:
00208 _x = self.multicast_address
00209 length = len(_x)
00210 buff.write(struct.pack('<I%ss'%length, length, _x))
00211 length = len(self.topics)
00212 buff.write(_struct_I.pack(length))
00213 for val1 in self.topics:
00214 _x = val1.topic
00215 length = len(_x)
00216 buff.write(struct.pack('<I%ss'%length, length, _x))
00217 buff.write(_struct_H.pack(val1.port))
00218 except struct.error, se: self._check_types(se)
00219 except TypeError, te: self._check_types(te)
00220
00221 def deserialize_numpy(self, str, numpy):
00222 """
00223 unpack serialized message in str into this message instance using numpy for array types
00224 @param str: byte array of serialized message
00225 @type str: str
00226 @param numpy: numpy python module
00227 @type numpy: module
00228 """
00229 try:
00230 end = 0
00231 start = end
00232 end += 4
00233 (length,) = _struct_I.unpack(str[start:end])
00234 start = end
00235 end += length
00236 self.multicast_address = str[start:end]
00237 start = end
00238 end += 4
00239 (length,) = _struct_I.unpack(str[start:end])
00240 self.topics = []
00241 for i in xrange(0, length):
00242 val1 = udpmulti_transport.msg.UDPMultTopic()
00243 start = end
00244 end += 4
00245 (length,) = _struct_I.unpack(str[start:end])
00246 start = end
00247 end += length
00248 val1.topic = str[start:end]
00249 start = end
00250 end += 2
00251 (val1.port,) = _struct_H.unpack(str[start:end])
00252 self.topics.append(val1)
00253 return self
00254 except struct.error, e:
00255 raise roslib.message.DeserializationError(e)
00256
00257 _struct_I = roslib.message.struct_I
00258 _struct_H = struct.Struct("<H")
00259 class UDPMultGetTopicList(roslib.message.ServiceDefinition):
00260 _type = 'udpmulti_transport/UDPMultGetTopicList'
00261 _md5sum = '22672cb98b49fe101a321cb17bceec21'
00262 _request_class = UDPMultGetTopicListRequest
00263 _response_class = UDPMultGetTopicListResponse