このページでは

QGrpcCancelInterceptor Class

RPC に対するキャンセル要求をインターセプトします。詳細...

ヘッダー: #include <QGrpcInterceptor>
CMake: find_package(Qt6 REQUIRED COMPONENTS Grpc)
target_link_libraries(mytarget PRIVATE Qt6::Grpc)
以下より: Qt 6.11

注:このクラスのすべての関数は再入可能です。

パブリック関数

virtual ~QGrpcCancelInterceptor()
virtual void onCancel(QGrpcInterceptionContext &context) = 0

詳細な説明

RPC のキャンセルが要求されたことを監視するには、QGrpcCancelInterceptor を実装してください。

インターセプトの仕組みや、インターセプタインターフェースが RPC のライフサイクルにどのように関与するかについての概要については、「Qt GRPC インターセプタの概要」を参照してください。

注:この インターセプタは 、インバウンド方向で動作します。複数のインターセプタ・コールバックがチェーン内をどのように流れるかについての詳細は、「方向と流れ」のセクションを参照してください。

関連項目: QtGrpc::InterceptorCapability::Cancel およびQGrpcInterceptionContext 。

メンバ関数のドキュメント

[virtual noexcept] QGrpcCancelInterceptor::~QGrpcCancelInterceptor()

インターセプターを破壊する。

[pure virtual] void QGrpcCancelInterceptor::onCancel(QGrpcInterceptionContext &context)

RPCのキャンセルが要求された際に呼び出されます。

context は、インターセプトされたRPCに関する情報を提供します。

QGrpcOperation::cancel()も参照してください 。

© 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.