このページでは

変更点Qt D-Bus

Qt 6 における変更点は、フレームワークをより効率的で使いやすくするための意図的な取り組みの結果です。

各リリースにおいて、すべての公開 API についてバイナリおよびソースの互換性を維持するよう努めています。しかし、Qt をより優れたフレームワークにするための取り組みにおいて、一部の変更は避けられませんでした。

このトピックでは、Qt DBus におけるそれらの変更点をまとめ、それらに対処するためのガイダンスを提供します。

API の変更

QtDBus モジュールには、基本的な統合と整理が行われました。Qt 6への移行にかかる移植作業は最小限で済むはずです。

QDBusMessage クラス

引数のサイズが固定されていた QDBusMessage::call() および QDBusMessage::asyncCall() メソッドは、Qt6 で削除されました。

QDBusArgument クラス

QHash 、QMap 、およびQList に対する QDBusArgument::operator<<() の特化は、連想コンテナ用の共通の特化に統合されました。

QDBusConnection クラス

Qt6 では、QDBusConnection::sender() 関数が削除されました。

QDBusMessage クラス

QDBusMessage::createErrorReply() 関数は、引数QString およびname を値渡しではなく、const 参照で受け取るようになりました。

QDBusPendingReply クラス

QDBusPendingReply は、8 つ以上のテンプレートパラメータをサポートできるよう、可変引数テンプレートクラスに変更されました。テンプレートパラメータは、応答データのコンテンツを抽出するために使用される型です。

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.