KVIrc  4.9.2
DeveloperAPIs
Public Member Functions | Private Attributes | Friends | List of all members
QHttpAuthenticator Class Reference

The QHttpAuthenticator class provides an authentication object. More...

#include <qhttpauthenticator_p.h>

Public Member Functions

void detach ()
 
bool isNull () const
 
bool operator!= (const QHttpAuthenticator &other) const
 
QHttpAuthenticatoroperator= (const QHttpAuthenticator &other)
 
QHttpAuthenticatoroperator= (const QAuthenticator &auth)
 
bool operator== (const QHttpAuthenticator &other) const
 
QVariant option (const QString &opt) const
 
QVariantHash options () const
 
QString password () const
 
 QHttpAuthenticator ()
 
 QHttpAuthenticator (const QHttpAuthenticator &other)
 
QString realm () const
 
void setOption (const QString &opt, const QVariant &value)
 
void setPassword (const QString &password)
 
void setUser (const QString &user)
 
QAuthenticator toQAuthenticator ()
 
QString user () const
 
 ~QHttpAuthenticator ()
 

Private Attributes

QHttpAuthenticatorPrivated
 

Friends

class QHttpAuthenticatorPrivate
 

Detailed Description

The QHttpAuthenticator class provides an authentication object.

Since
4.3

QtNetwork

The QHttpAuthenticator class is usually used in the {QNetworkAccessManager::}{authenticationRequired()} and {QNetworkAccessManager::}{proxyAuthenticationRequired()} signals of QNetworkAccessManager and QAbstractSocket. The class provides a way to pass back the required authentication information to the socket when accessing services that require authentication.

QHttpAuthenticator supports the following authentication methods: Basic NTLM version 1 Digest-MD5

Note that, in particular, NTLM version 2 is not supported.

Constructor & Destructor Documentation

QHttpAuthenticator::QHttpAuthenticator ( )

Constructs an empty authentication object

QHttpAuthenticator::~QHttpAuthenticator ( )

Destructs the object

References d, and QHttpAuthenticatorPrivate::ref.

QHttpAuthenticator::QHttpAuthenticator ( const QHttpAuthenticator other)

Constructs a copy of other.

References d, and QHttpAuthenticatorPrivate::ref.

Member Function Documentation

void QHttpAuthenticator::detach ( )
bool QHttpAuthenticator::isNull ( ) const

Returns true if the authenticator is null.

References d.

Referenced by QHttpPrivate::_q_slotReadyRead().

bool QHttpAuthenticator::operator!= ( const QHttpAuthenticator other) const
inline

Returns true if this authenticator is different from other; otherwise returns false.

References operator==().

QHttpAuthenticator & QHttpAuthenticator::operator= ( const QHttpAuthenticator other)

Assigns the contents of other to this authenticator.

References d, and QHttpAuthenticatorPrivate::ref.

QHttpAuthenticator & QHttpAuthenticator::operator= ( const QAuthenticator &  auth)
bool QHttpAuthenticator::operator== ( const QHttpAuthenticator other) const

Returns true if this authenticator is identical to other; otherwise returns false.

References d, QHttpAuthenticatorPrivate::method, QHttpAuthenticatorPrivate::options, QHttpAuthenticatorPrivate::password, QHttpAuthenticatorPrivate::realm, and QHttpAuthenticatorPrivate::user.

Referenced by operator!=().

QVariant QHttpAuthenticator::option ( const QString &  opt) const
Since
4.7 Returns the value related to option opt if it was set by the server. See {QHttpAuthenticator::Options} for more information on incoming options. If option opt isn't found, an invalid QVariant will be returned.
See also
options(), QHttpAuthenticator::Options

References d, and QHttpAuthenticatorPrivate::options.

Referenced by toQAuthenticator().

QVariantHash QHttpAuthenticator::options ( ) const
Since
4.7 Returns all incoming options set in this QHttpAuthenticator object by parsing the server reply. See {QHttpAuthenticator::Options} for more information on incoming options.
See also
option(), QHttpAuthenticator::Options

References d, and QHttpAuthenticatorPrivate::options.

QString QHttpAuthenticator::password ( ) const

returns the password used for authentication.

References d, and QHttpAuthenticatorPrivate::password.

Referenced by setPassword().

QString QHttpAuthenticator::realm ( ) const

returns the realm requiring authentication.

References d, and QHttpAuthenticatorPrivate::realm.

void QHttpAuthenticator::setOption ( const QString &  opt,
const QVariant &  value 
)
Since
4.7

Sets the outgoing option opt to value value. See {QHttpAuthenticator::Options} for more information on outgoing options.

See also
options(), option(), QHttpAuthenticator::Options

References d, detach(), and QHttpAuthenticatorPrivate::options.

void QHttpAuthenticator::setPassword ( const QString &  password)

Sets the password used for authentication.

See also
QNetworkAccessManager::authenticationRequired()

References d, detach(), password(), and QHttpAuthenticatorPrivate::password.

void QHttpAuthenticator::setUser ( const QString &  user)
QAuthenticator QHttpAuthenticator::toQAuthenticator ( )
QString QHttpAuthenticator::user ( ) const

returns the user used for authentication.

References d, and QHttpAuthenticatorPrivate::user.

Referenced by setUser().

Friends And Related Function Documentation

friend class QHttpAuthenticatorPrivate
friend

Referenced by detach().

Member Data Documentation

QHttpAuthenticatorPrivate* QHttpAuthenticator::d
private

The documentation for this class was generated from the following files: