'Iterate over the user\'s notification.
:param bool all: (optional), iterate over all notifications
:param bool participating: (optional), only iterate over notifications
in which the user is participating
:param int number: (optional), how many notifications to return
:param str etag: (optional), ETag from a previous request to the same
endpoint
:returns: generator of
:class:`Thread <github3.notifications.Thread>`'

@requires_auth
def notifications(self, all=False, participating=False, number=(-1), etag=None):

    params = None
    if (all is True):
        params = {u'all': u'true'}
    elif (participating is True):
        params = {u'participating': u'true'}
    url = self._build_url(u'notifications')
    return self._iter(int(number), url, Thread, params, etag=etag)
