The QGrpcUserPasswordCredentials class is a reference implementation of simple user-password call authentication. 更多...
头: | #include <QGrpcUserPasswordCredentials> |
CMake: |
find_package(Qt6 REQUIRED COMPONENTS Grpc)
target_link_libraries(mytarget PRIVATE Qt6::Grpc) |
Since: | Qt 6.5 |
继承: | QGrpcCallCredentials |
QGrpcUserPasswordCredentials (const QString & userName , const QString & password ) | |
QGrpcUserPasswordCredentials (const QByteArray & userNameField , const QString & userName , const QByteArray & passwordField , const QString & password ) | |
virtual | ~QGrpcUserPasswordCredentials () override |
virtual QGrpcCredentialMap | operator() () const override |
[explicit]
QGrpcUserPasswordCredentials::
QGrpcUserPasswordCredentials
(const
QString
&
userName
, const
QString
&
password
)
QGrpcUserPasswordCredentials constructs QGrpcUserPasswordCredentials with
userName
and
password
with default UserFieldName and PasswordFieldName header keys. The
userNameField
默认为
"user-name"
,
passwordField
默认为
"user-password"
.
[explicit]
QGrpcUserPasswordCredentials::
QGrpcUserPasswordCredentials
(const
QByteArray
&
userNameField
, const
QString
&
userName
, const
QByteArray
&
passwordField
, const
QString
&
password
)
QGrpcUserPasswordCredentials constructs QGrpcUserPasswordCredentials with userName and password credentials with manually specified userNameField and passwordField header keys.
[override virtual]
QGrpcUserPasswordCredentials::
~QGrpcUserPasswordCredentials
()
销毁 QGrpcUserPasswordCredentials 对象。
[override virtual]
QGrpcCredentialMap
QGrpcUserPasswordCredentials::
operator()
() const
重实现: QGrpcCallCredentials::operator()() const .
Returns the stored credentials map.