1 """autogenerated by genpy from web_msgs/WebEvent.msg. Do not edit.""" 3 python3 =
True if sys.hexversion > 0x03000000
else False 9 _md5sum =
"4f05e2e1608bf7d788fa5e654f805aeb" 10 _type =
"web_msgs/WebEvent" 12 _full_text =
"""string source # who or what triggered the event 13 string type # type of event (e.g. login, logout) 14 string data # any data about the event 16 __slots__ = [
'source',
'type',
'data']
17 _slot_types = [
'string',
'string',
'string']
21 Constructor. Any message fields that are implicitly/explicitly 22 set to None will be assigned a default value. The recommend 23 use is keyword arguments as this is more robust to future message 24 changes. You cannot mix in-order arguments and keyword arguments. 26 The available fields are: 29 :param args: complete set of field values, in .msg order 30 :param kwds: use keyword arguments corresponding to message field names 31 to set specific fields. 34 super(WebEvent, self).
__init__(*args, **kwds)
55 serialize message into buffer 56 :param buff: buffer, ``StringIO`` 61 if python3
or type(_x) == unicode:
62 _x = _x.encode(
'utf-8')
64 buff.write(struct.pack(
'<I%ss'%length, length, _x))
67 if python3
or type(_x) == unicode:
68 _x = _x.encode(
'utf-8')
70 buff.write(struct.pack(
'<I%ss'%length, length, _x))
73 if python3
or type(_x) == unicode:
74 _x = _x.encode(
'utf-8')
76 buff.write(struct.pack(
'<I%ss'%length, length, _x))
77 except struct.error
as se: self._check_types(struct.error(
"%s: '%s' when writing '%s'" % (
type(se), str(se), str(_x))))
78 except TypeError
as te: self._check_types(ValueError(
"%s: '%s' when writing '%s'" % (
type(te), str(te), str(_x))))
82 unpack serialized message in str into this message instance 83 :param str: byte array of serialized message, ``str`` 89 (length,) = _struct_I.unpack(str[start:end])
93 self.
source = str[start:end].decode(
'utf-8')
95 self.
source = str[start:end]
98 (length,) = _struct_I.unpack(str[start:end])
102 self.
type = str[start:end].decode(
'utf-8')
104 self.
type = str[start:end]
107 (length,) = _struct_I.unpack(str[start:end])
111 self.
data = str[start:end].decode(
'utf-8')
113 self.
data = str[start:end]
115 except struct.error
as e:
116 raise genpy.DeserializationError(e)
121 serialize message with numpy array types into buffer 122 :param buff: buffer, ``StringIO`` 123 :param numpy: numpy python module 128 if python3
or type(_x) == unicode:
129 _x = _x.encode(
'utf-8')
131 buff.write(struct.pack(
'<I%ss'%length, length, _x))
134 if python3
or type(_x) == unicode:
135 _x = _x.encode(
'utf-8')
137 buff.write(struct.pack(
'<I%ss'%length, length, _x))
140 if python3
or type(_x) == unicode:
141 _x = _x.encode(
'utf-8')
143 buff.write(struct.pack(
'<I%ss'%length, length, _x))
144 except struct.error
as se: self._check_types(struct.error(
"%s: '%s' when writing '%s'" % (
type(se), str(se), str(_x))))
145 except TypeError
as te: self._check_types(ValueError(
"%s: '%s' when writing '%s'" % (
type(te), str(te), str(_x))))
149 unpack serialized message in str into this message instance using numpy for array types 150 :param str: byte array of serialized message, ``str`` 151 :param numpy: numpy python module 157 (length,) = _struct_I.unpack(str[start:end])
161 self.
source = str[start:end].decode(
'utf-8')
163 self.
source = str[start:end]
166 (length,) = _struct_I.unpack(str[start:end])
170 self.
type = str[start:end].decode(
'utf-8')
172 self.
type = str[start:end]
175 (length,) = _struct_I.unpack(str[start:end])
179 self.
data = str[start:end].decode(
'utf-8')
181 self.
data = str[start:end]
183 except struct.error
as e:
184 raise genpy.DeserializationError(e)
186 _struct_I = genpy.struct_I
def deserialize(self, str)
def serialize(self, buff)
def deserialize_numpy(self, str, numpy)
def __init__(self, args, kwds)
def serialize_numpy(self, buff, numpy)