def __call__(self, event_type, details):
        """Activate the target callback with the given event + details.

        NOTE(harlowja): if a details filter callback exists and it returns
        a falsey value when called with the provided ``details``, then the
        target callback will **not** be called.
        """
        cb = self.callback
        if cb is None:
            return
        if self._details_filter is not None:
            if not self._details_filter(details):
                return
        kwargs = dict(self._kwargs)
        kwargs['details'] = details
        cb(event_type, *self._args, **kwargs)
def __call__ ( self , event_type , details ) : cb = self . callback if cb is None : return if self . _details_filter is not None : if not self . _details_filter ( details ) : return kwargs = dict ( self . _kwargs ) kwargs [ 'details' ] = details cb ( event_type , * self . _args , ** kwargs )
Activate the target callback with the given event + details.

        NOTE(harlowja): if a details filter callback exists and it returns
        a falsey value when called with the provided ``details``, then the
        target callback will **not** be called.