2013-10-26 09:41:45 +02:00
|
|
|
#include "base/dynamicobject.h"
|
|
|
|
|
|
|
|
namespace icinga
|
|
|
|
{
|
|
|
|
|
2014-04-05 22:17:20 +02:00
|
|
|
code {{{
|
2014-04-06 08:09:49 +02:00
|
|
|
class I2_ICINGA_API NotificationNameComposer : public NameComposer
|
2014-04-05 22:17:20 +02:00
|
|
|
{
|
|
|
|
public:
|
2014-04-06 08:09:49 +02:00
|
|
|
virtual String MakeName(const String& shortName, const Dictionary::Ptr props) const;
|
2014-04-05 22:17:20 +02:00
|
|
|
};
|
|
|
|
}}}
|
|
|
|
|
2014-04-06 08:09:49 +02:00
|
|
|
class Notification : DynamicObject < NotificationNameComposer
|
2013-10-26 09:41:45 +02:00
|
|
|
{
|
|
|
|
[config, protected] String notification_command (NotificationCommandRaw);
|
|
|
|
[config] double notification_interval {
|
|
|
|
default {{{ return 300; }}}
|
|
|
|
};
|
|
|
|
[config] String notification_period (NotificationPeriodRaw);
|
|
|
|
[config] Dictionary::Ptr macros;
|
|
|
|
[config, protected] Array::Ptr users (UsersRaw);
|
|
|
|
[config, protected] Array::Ptr user_groups (UserGroupsRaw);
|
|
|
|
[config] Dictionary::Ptr times;
|
2014-04-07 13:59:41 +02:00
|
|
|
[config] Array::Ptr notification_type_filter (NotificationTypeFilterRaw);
|
|
|
|
int notification_type_filter_real (NotificationTypeFilter);
|
|
|
|
[config] Array::Ptr notification_state_filter (NotificationStateFilterRaw);
|
|
|
|
int notification_state_filter_real (NotificationStateFilter);
|
2014-04-05 09:15:40 +02:00
|
|
|
[config, protected] String host_name;
|
|
|
|
[config, protected] String service_name;
|
2013-10-26 09:41:45 +02:00
|
|
|
|
|
|
|
[state] double last_notification;
|
|
|
|
[state, set_protected] double next_notification (NextNotificationRaw);
|
|
|
|
[state, set_protected] Value notification_number;
|
2013-11-06 08:36:22 +01:00
|
|
|
[state] double last_problem_notification;
|
2013-10-26 09:41:45 +02:00
|
|
|
};
|
|
|
|
|
2013-11-06 08:36:22 +01:00
|
|
|
}
|