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