def set_event(self, event):
self._event = event<EOL>if len(self._buffer) > <NUM_LIT:0>:<EOL><INDENT>event.set()<EOL><DEDENT>else:<EOL><INDENT>event.clear()<EOL><DEDENT>
Set an event on this buffer.  When data is ready to be read (or the
buffer has been closed), the event will be set.  When no data is
ready, the event will be cleared.

@param event: the event to set/clear
@type event: Event