c++ - 在 omnetpp 中定义模块时出现问题

标签 c++ package simulation

嗨 我正在 omnet 中编写一个项目,但我一直坚持定义自己的模块。在 https://github.com/lbedogni/Basic-Broadcast-Simulation有完整的代码。问题是我收到以下错误消息:

<!> Error in module (cCompoundModule) scenario.host[0] (id=4) at event 
\#1, t=0: Class "basic::Flooding" not found -- perhaps its code was not 
linked in, or the class wasn't registered with Register_Class(), or in 
the case of modules and channels, with 
Define_Module()/Define_Channel(). 

但我通过 Define_Module() 定义了它。

我认为这可能是与包相关的问题,但没有找到解决方案。有什么想法吗?

谢谢

最佳答案

我不熟悉,但是来自package.ned

//指定该文件夹的NED包 基础包;

//模块 C++ 类的命名空间 @命名空间(基本);

@license(LGPL);

我猜你需要在命名空间 basic 中?

而且您的泛洪类没有在命名空间 basic 中定义?

关于c++ - 在 omnetpp 中定义模块时出现问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4385469/

相关文章:

dependencies - NuGet:pack命令不包括nuget依赖项

git - 使用 git 设置正确的 Golang 目录结构以在自定义包上使用 go build

ios - 在不连接到 Xcode 的情况下在设备上模拟 GPX 文件

c - C : generation for Monte Carlo simulation without atmospheric noise 中的任意精度随机数

c++ - 显式销毁非指针静态对象

C++ 在为 "new"类型专门化模板时如何预定义构造函数参数

c++ - 类模板继承 C++

C++ 将选项(的子集)传递给函数的优雅方式

java - 在 Spark 提交期间抛出 NoClassDefFoundError

python - 抛硬币模拟意外概率