polserver/pol-core/bscript/fmodule.h
turleypol 21577d8e5b
Clang Tidy concat namespaces (#855)
* tidy

* Automated clang-tidy change: modernize-concat-nested-namespaces

* compile test

* fix namespace

---------

Co-authored-by: Clang Tidy <clang-tidy@users.noreply.github.com>
2026-01-17 10:30:21 +01:00

48 lines
877 B
C++

/** @file
*
* @par History
*/
#ifndef FMODULE_H
#define FMODULE_H
#include <map>
#include <stddef.h>
#include <string>
#include <vector>
#include "../clib/boostutils.h"
#include "../clib/maputil.h"
namespace Pol::Bscript
{
class ModuleFunction
{
public:
boost_utils::function_name_flystring name;
unsigned nargs;
int funcidx; // according to the executor, what's its function index
ModuleFunction( const char* fname, int nargs );
~ModuleFunction() = default;
};
class FunctionalityModule
{
public:
bool have_indexes;
std::vector<ModuleFunction*> functions;
boost_utils::function_name_flystring modulename;
explicit FunctionalityModule( const char* modname );
FunctionalityModule( const FunctionalityModule& ) = delete;
~FunctionalityModule();
void addFunction( const char* funcname, int nparams );
};
} // namespace Pol::Bscript
#endif