code: def want_service_notification(self, notifways, timeperiods,
                                    timestamp, state, n_type, business_impact, cmd=None):
          if not self.service_notifications_enabled:
              return False
          for downtime_id in self.downtimes:
              downtime = self.downtimes[downtime_id]
              if downtime.is_in_effect:
                  self.in_scheduled_downtime = True
                  return False
          self.in_scheduled_downtime = False
          for notifway_id in self.notificationways:
              notifway = notifways[notifway_id]
              nw_b = notifway.want_service_notification(timeperiods, timestamp,
                                                        state, n_type, business_impact, cmd)
              if nw_b:
                  return True
          return False