Deprecate plugin::HookType and plugin::component::Type in a different way

This commit is contained in:
Tim Wojtulewicz 2020-06-30 13:38:39 -07:00
parent 7ee8e11a8f
commit b1b1ec5171
8 changed files with 65 additions and 233 deletions

View file

@ -171,16 +171,6 @@ public:
return hooks[hook] != nullptr;
}
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
[[deprecated("Remove in v4.1. Use the version that takes zeek::plugin::HookType")]]
bool HavePluginForHook(::plugin::HookType hook) const
{
// Inline to avoid the function call.
return HavePluginForHook(static_cast<zeek::plugin::HookType>(hook));
}
#pragma GCC diagnostic pop
/**
* Returns all the hooks, with their priorities, that are currently
* enabled for a given plugin.
@ -209,15 +199,6 @@ public:
*/
void DisableHook(zeek::plugin::HookType hook, Plugin* plugin);
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
[[deprecated("Remove in v4.1. Use the version that takes zeek::plugin::HookType")]]
void EnableHook(::plugin::HookType hook, Plugin* plugin, int prio);
[[deprecated("Remove in v4.1. Use the version that takes zeek::plugin::HookType")]]
void DisableHook(::plugin::HookType hook, Plugin* plugin);
#pragma GCC diagnostic pop
/**
* Registers interest in an event by a plugin, even if there's no handler
* for it. Normally a plugin receives events through HookQueueEvent()