Move Func and associated classes into zeek::detail namespace

This commit is contained in:
Tim Wojtulewicz 2020-06-22 15:45:40 -07:00
parent 937a462e70
commit d6f1ea16ac
51 changed files with 516 additions and 453 deletions

View file

@ -17,9 +17,9 @@
#define BRO_PLUGIN_BRO_VERSION BRO_VERSION_FUNCTION
class ODesc;
class Func;
class Event;
ZEEK_FORWARD_DECLARE_NAMESPACED(Func, zeek::detail);
ZEEK_FORWARD_DECLARE_NAMESPACED(Frame, zeek::detail);
namespace zeek {
@ -201,7 +201,7 @@ public:
/**
* Constructor with a function argument.
*/
explicit HookArgument(const Func* a) { type = FUNC; arg.func = a; }
explicit HookArgument(const zeek::detail::Func* a) { type = FUNC; arg.func = a; }
/**
* Constructor with an integer argument.
@ -286,7 +286,7 @@ public:
* Returns the value for a function argument. The argument's type must
* match accordingly.
*/
const Func* AsFunc() const { assert(type == FUNC); return arg.func; }
const zeek::detail::Func* AsFunc() const { assert(type == FUNC); return arg.func; }
/**
* Returns the value for an integer argument. The argument's type must
@ -366,7 +366,7 @@ private:
double double_;
const Event* event;
const Connection* conn;
const Func* func;
const zeek::detail::Func* func;
const zeek::detail::Frame* frame;
int int_;
const Val* val;
@ -674,10 +674,10 @@ protected:
* pair with the first member set to 'false' and null result value.
*/
virtual std::pair<bool, ValPtr>
HookFunctionCall(const Func* func, zeek::detail::Frame* parent, zeek::Args* args);
HookFunctionCall(const zeek::detail::Func* func, zeek::detail::Frame* parent, zeek::Args* args);
[[deprecated("Remove in v4.1. Use HookFunctionCall()")]]
virtual std::pair<bool, Val*> HookCallFunction(const Func* func, zeek::detail::Frame *parent, val_list* args);
virtual std::pair<bool, Val*> HookCallFunction(const zeek::detail::Func* func, zeek::detail::Frame *parent, val_list* args);
/**
* Hook into raising events. Whenever the script interpreter is about