mirror of
https://github.com/zeek/zeek.git
synced 2025-10-10 18:48:20 +00:00
Use std::function instead of a function pointer in packet_analysis::Component
This commit is contained in:
parent
43f7b3beab
commit
1f02bd5147
1 changed files with 1 additions and 1 deletions
|
@ -17,7 +17,7 @@ using AnalyzerPtr = std::shared_ptr<Analyzer>;
|
||||||
class Component : public plugin::Component,
|
class Component : public plugin::Component,
|
||||||
public plugin::TaggedComponent<packet_analysis::Tag> {
|
public plugin::TaggedComponent<packet_analysis::Tag> {
|
||||||
public:
|
public:
|
||||||
typedef AnalyzerPtr (*factory_callback)();
|
using factory_callback = std::function<AnalyzerPtr ()>;
|
||||||
|
|
||||||
Component(const std::string& name, factory_callback factory, Tag::subtype_t subtype = 0);
|
Component(const std::string& name, factory_callback factory, Tag::subtype_t subtype = 0);
|
||||||
~Component() override = default;
|
~Component() override = default;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue