Obsolete Members for QNetworkAccessManager

The following members of class QNetworkAccessManager are obsolete. They are provided to keep old source code working. We strongly advise against using them in new code.

Public Types

(obsolete) enum NetworkAccessibility { UnknownAccessibility, NotAccessible, Accessible }

Properties

Public Functions

(obsolete) QNetworkAccessManager::NetworkAccessibility networkAccessible() const
(obsolete) void setNetworkAccessible(QNetworkAccessManager::NetworkAccessibility accessible)

Signals

(obsolete) void networkAccessibleChanged(QNetworkAccessManager::NetworkAccessibility accessible)

Member Type Documentation

enum QNetworkAccessManager::NetworkAccessibility

This enum is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.

Indicates whether the network is accessible via this network access manager.

ConstantValueDescription
QNetworkAccessManager::UnknownAccessibility-1The network accessibility cannot be determined.
QNetworkAccessManager::NotAccessible0The network is not currently accessible, either because there is currently no network coverage or network access has been explicitly disabled by a call to setNetworkAccessible().
QNetworkAccessManager::Accessible1The network is accessible.

See also networkAccessible.

Property Documentation

networkAccessible : NetworkAccessibility

This property is obsolete. It is provided to keep old source code working. We strongly advise against using it in new code.

This property holds whether the network is currently accessible via this network access manager.

If the network is not accessible the network access manager will not process any new network requests, all such requests will fail with an error. Requests with URLs with the file:// scheme will still be processed.

By default the value of this property reflects the physical state of the device. Applications may override it to disable all network requests via this network access manager by calling

 networkAccessManager->setNetworkAccessible(QNetworkAccessManager::NotAccessible);

Network requests can be re-enabled again, and this property will resume to reflect the actual device state by calling

 networkAccessManager->setNetworkAccessible(QNetworkAccessManager::Accessible);

Note: Calling setNetworkAccessible() does not change the network state.

This property was introduced in Qt 4.7.

Access functions:

QNetworkAccessManager::NetworkAccessibility networkAccessible() const
void setNetworkAccessible(QNetworkAccessManager::NetworkAccessibility accessible)

Notifier signal:

void networkAccessibleChanged(QNetworkAccessManager::NetworkAccessibility accessible)