嗨 我正在 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/