'Removes all registered callbacks.'

def remove_all_callbacks(self):

    for cb in list(self._next_tick_callbacks.keys()):
        self.remove_next_tick_callback(cb)
    for cb in list(self._timeout_callbacks.keys()):
        self.remove_timeout_callback(cb)
    for cb in list(self._periodic_callbacks.keys()):
        self.remove_periodic_callback(cb)
