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