def write_event(self, event):
<EOL>if not isinstance(event, event_pb2.Event):<EOL><INDENT>raise TypeError("<STR_LIT>"<EOL>"<STR_LIT>" % type(event))<EOL><DEDENT>return self._write_serialized_event(event.SerializeToString())<EOL>
Appends event to the file.