QGrpcInterceptionContext Class
Fournit des informations contextuelles aux callbacks des intercepteurs. En savoir plus...
| En-tête : | #include <QGrpcInterceptor> |
| CMake : | find_package(Qt6 REQUIRED COMPONENTS Grpc) target_link_libraries(mytarget PRIVATE Qt6::Grpc) |
| Depuis : | Qt 6.11 |
- Liste de tous les membres, y compris les membres hérités
- QGrpcInterceptionContext fait partie de la classe « Intercepteurs » d'Qt GRPC .
Fonctions publiques
| QGrpcInterceptionContext(const QGrpcInterceptionContext &) | |
| QGrpcInterceptionContext(QGrpcInterceptionContext &&) | |
| ~QGrpcInterceptionContext() | |
| const QGrpcCallOptions & | callOptions() const & |
| const QAbstractGrpcChannel & | channel() const & |
| QtGrpc::RpcDescriptor | descriptor() const |
| quint64 | operationId() const |
| quint32 | version() const |
| QGrpcInterceptionContext & | operator=(QGrpcInterceptionContext &&) |
| QGrpcInterceptionContext & | operator=(const QGrpcInterceptionContext &) |
Description détaillée
QGrpcInterceptionContext est transmis aux rappels d’intercepteur et permet d’accéder aux informations relatives au RPC intercepté, telles que le canal, le descripteur RPC ou les options d’appel.
Une instance de `QGrpcInterceptionContext` est créée par ` Qt GRPC ` pour chaque invocation de rappel. L’objet contexte n’est valide que pendant la durée du rappel et ne doit pas être stocké.
Remarque : QGrpcInterceptionContext ne peut être ni copié ni déplacé.
Voir également QGrpcStartInterceptor, QGrpcInitialMetadataInterceptor, QGrpcMessageReceivedInterceptor, QGrpcWriteMessageInterceptor, QGrpcWritesDoneInterceptor, QGrpcTrailingMetadataInterceptor, QGrpcFinishedInterceptor et QGrpcCancelInterceptor.
Documentation sur les fonctions membres
[delete] QGrpcInterceptionContext::QGrpcInterceptionContext(const QGrpcInterceptionContext &)
Copie et construit une instance de ` QGrpcInterceptionContext`. Cette fonction est supprimée.
[delete] QGrpcInterceptionContext::QGrpcInterceptionContext(QGrpcInterceptionContext &&)
Crée par « move » une instance de ` QGrpcInterceptionContext`. Cette fonction est supprimée.
[constexpr noexcept default] QGrpcInterceptionContext::~QGrpcInterceptionContext()
Supprime l'instance de ` QGrpcInterceptionContext`.
[noexcept] const QGrpcCallOptions &QGrpcInterceptionContext::callOptions() const &
Renvoie les options d'appel en vigueur pour le RPC intercepté.
[noexcept] const QAbstractGrpcChannel &QGrpcInterceptionContext::channel() const &
Renvoie le canal utilisé pour le RPC intercepté.
[noexcept] QtGrpc::RpcDescriptor QGrpcInterceptionContext::descriptor() const
Renvoie le descripteur identifiant le RPC intercepté.
[noexcept] quint64 QGrpcInterceptionContext::operationId() const
Renvoie l'identifiant unique de l'appel intercepté.
Chaque identifiant est unique sur tous les canaux pendant toute la durée de vie de l'application.
Cet identifiant peut être utilisé pour corréler les rappels d'interception appartenant à la même opération RPC sur plusieurs points de raccrochage.
[noexcept] quint32 QGrpcInterceptionContext::version() const
Renvoie la version du contexte d'interception.
Les futures versions de Qt pourraient étendre la fonction ` QGrpcInterceptionContext`. Cette fonction peut être utilisée pour identifier la révision prise en charge du contexte.
[delete] QGrpcInterceptionContext &QGrpcInterceptionContext::operator=(QGrpcInterceptionContext &&)
La commande « Move » affecte « other » à cette instance « QGrpcInterceptionContext ». Cette fonction est supprimée.
[delete] QGrpcInterceptionContext &QGrpcInterceptionContext::operator=(const QGrpcInterceptionContext &)
Copie et attribue la classe « other » à cette instance « QGrpcInterceptionContext ». Cette fonction est supprimée.
© 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.