2019-02-25 08:48:22 -05:00
|
|
|
/* Icinga 2 | (c) 2012 Icinga GmbH | GPLv2+ */
|
2013-06-13 05:33:00 -04:00
|
|
|
|
2014-05-25 10:23:35 -04:00
|
|
|
#include "icinga/notificationcommand.hpp"
|
2018-01-18 07:50:38 -05:00
|
|
|
#include "icinga/notificationcommand-ti.cpp"
|
2013-06-13 05:33:00 -04:00
|
|
|
|
|
|
|
|
using namespace icinga;
|
|
|
|
|
|
|
|
|
|
REGISTER_TYPE(NotificationCommand);
|
|
|
|
|
|
2020-07-31 11:28:33 -04:00
|
|
|
thread_local NotificationCommand::Ptr NotificationCommand::ExecuteOverride;
|
|
|
|
|
|
2013-06-13 05:33:00 -04:00
|
|
|
Dictionary::Ptr NotificationCommand::Execute(const Notification::Ptr& notification,
|
2020-01-07 08:21:06 -05:00
|
|
|
const User::Ptr& user, const CheckResult::Ptr& cr, const NotificationType& type,
|
|
|
|
|
const String& author, const String& comment, const Dictionary::Ptr& resolvedMacros,
|
|
|
|
|
bool useResolvedMacros)
|
2013-06-13 05:33:00 -04:00
|
|
|
{
|
2017-11-30 02:19:58 -05:00
|
|
|
return GetExecute()->Invoke({
|
2017-12-19 09:50:05 -05:00
|
|
|
notification,
|
|
|
|
|
user,
|
|
|
|
|
cr,
|
|
|
|
|
type,
|
|
|
|
|
author,
|
|
|
|
|
comment,
|
|
|
|
|
resolvedMacros,
|
|
|
|
|
useResolvedMacros,
|
2017-11-30 02:19:58 -05:00
|
|
|
});
|
2013-06-13 05:33:00 -04:00
|
|
|
}
|