QAbstractGrpcCredentials Class

The QAbstractGrpcClient is an abstract storage class used by authentication parameters. 更多...

头: #include <QAbstractGrpcCredentials>
CMake: find_package(Qt6 REQUIRED COMPONENTS Grpc)
target_link_libraries(mytarget PRIVATE Qt6::Grpc)
Since: Qt 6.5
继承者: QGrpcCredentials

公共函数

virtual QGrpcCredentialMap callCredentials () const = 0
virtual QGrpcCredentialMap channelCredentials () const = 0
QGrpcCredentialMap

详细描述

QAbstractGrpcCredentials provides a set of functions to access the call and the channel credentials that are used by gRPC channels to communicate with the services.

You may implement this interface to create your own authentication provider class, but we recommend using the QGrpcCredentials with QGrpcUserPasswordCredentials and QGrpcSslCredentials .

成员函数文档编制

[pure virtual] QGrpcCredentialMap QAbstractGrpcCredentials:: callCredentials () const

This pure virtual function returns a key-value map of the credentials for RPC calls.

This function is called to obtain the QGrpcCredentialMap for the call.

[pure virtual] QGrpcCredentialMap QAbstractGrpcCredentials:: channelCredentials () const

This pure virtual function shall return a key-value map of session parameters for the specific channel.

This function is called to obtain the QGrpcCredentialMap for the channel.

相关非成员

[alias] QGrpcCredentialMap

别名化的 QMap<QByteArray, QVariant> . This is the key-value map of credentials, such as user-password credentials or session parameters.