SWIG is fully aware of issues related to C++ inheritance. Therefore, if you have classes like this
class Foo {
...
};
class Bar : public Foo {
...
};
those classes are wrapped into a hierarchy of Python classes that reflect the same inheritance structure. All of the usual Python utility functions work normally:
你应该不用再费劲了。以下是来自http://www.swig.org/Doc1.3/Python.html#Python_nn21的一些文档。在
答案似乎是swig接口文件中include文件的实际顺序。在
通过将基类头放在派生类之前,一切似乎都按预期开始工作。在
对任何人来说,看到警告
将提供一个没有预期基类功能的python对象。在
相关问题 更多 >
编程相关推荐