开发者

Can a PyQt program consume a DBus interface that exposes custom C++ types (marhsalled via Qt's MetaType system)? If so, how?

I have a Qt/C++ application that exposes some custom C++ classes via DBus methods (by registering them as MetaTypes, and using annotations in the xml), and I want开发者_运维问答 my PyQt program to consume these methods.

The problem I see is that the exposed types are C++ classes, not python, so how can I make python aware of these classes?


There is no such thing as 'C++ classes' in D-Bus, it is language-agnostic. All methods, functions, etc. have type signatures expressible in basic D-Bus types (see the spec). Just call those classes, and it should work.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜