QProtobufJsonSerializer Class
QProtobufJsonSerializer クラスは、QProtobufMessage オブジェクトをJSON形式にシリアライズおよびデシリアライズするための基本機能を表すインターフェースです。詳細...
| ヘッダー: | #include <QProtobufJsonSerializer> |
| CMake: | find_package(Qt6 REQUIRED COMPONENTS Protobuf) target_link_libraries(mytarget PRIVATE Qt6::Protobuf) |
| 以下より: | Qt 6.7 |
| 継承元: | QAbstractProtobufSerializer |
再実装されたパブリック関数
| virtual QAbstractProtobufSerializer::Error | lastError() const override |
| virtual QString | lastErrorString() const override |
詳細な説明
QProtobufJsonSerializer クラスは、QProtobufMessage を継承し、protobuf メッセージを実装するクラスに対して、シリアライザおよびデシリアライザを登録します。これらのクラスは、.proto ファイルに基づいて、CMake関数qt_add_protobufを使用するか、qtprotobufgenを直接実行することで自動的に生成されます。
メンバ関数のドキュメント
[override virtual] QAbstractProtobufSerializer::Error QProtobufJsonSerializer::lastError() const
再実装:QAbstractProtobufSerializer::lastError() const。
シリアライザインスタンスの最後のデシリアライズエラーを返します。
lastErrorString()も参照してください 。
[override virtual] QString QProtobufJsonSerializer::lastErrorString() const
再実装:QAbstractProtobufSerializer::lastErrorString() const。
シリアライザインスタンスの最後のデシリアライズエラーの文字列を返します。
lastError()も参照してください 。
© 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.