KIO
KIO::AccessManager Class Reference
A KDE implementation of QNetworkAccessManager. More...
#include <accessmanager.h>

Public Types | |
| enum | Attribute { MetaData = QNetworkRequest::User, KioError } |
Public Member Functions | |
| AccessManager (QObject *parent) | |
| virtual | ~AccessManager () |
| bool | isExternalContentAllowed () const |
| void | setExternalContentAllowed (bool allowed) |
Protected Member Functions | |
| virtual QNetworkReply * | createRequest (Operation op, const QNetworkRequest &req, QIODevice *outgoingData=0) |
Detailed Description
A KDE implementation of QNetworkAccessManager.
Use this class instead of QNetworkAccessManager if you want to integrate with KDE's KIO module for network operations.
Here is a simple example that shows how to set the QtWebKit module to use KDE's KIO for its network operations:
QWebView *view = new QWebView(this); KIO::Integration::AccessManager *manager = new KIO::Integration::AccessManager(view); view->page()->setNetworkAccessManager(manager);
To access member functions in the cookiejar class at a later point in your code simply downcast the pointer returned by QWebPage::networkAccessManager as follows:
KIO::Integration::AccessManager *manager = qobject_cast<KIO::Integration::AccessManager*>(view->page()->accessManager());
Please note that this class is in the KIO namespace for backward compatiblity. You should use KIO::Integration::AccessManager to access this class in your code.
IMPORTANTThis class is not a replacement for the standard KDE API. It should ONLY be used to to provide KDE integration in applications that cannot use the standard KDE API directly.
- Deprecated:
- Use the KIO::Integration::AccessManager typedef to access this class instead.
- Since:
- 4.3
Definition at line 68 of file accessmanager.h.
Member Enumeration Documentation
Extensions to QNetworkRequest::Attribute enums.
- Since:
- 4.3.2
- Enumerator:
MetaData KioError < Used to send KIO MetaData back and forth.
type: QVariant::Map. Used to send KIO error codes that cannot be mapped into QNetworkReply::NetworkError. type: QVariant::Int
Definition at line 76 of file accessmanager.h.
Constructor & Destructor Documentation
| AccessManager::AccessManager | ( | QObject * | parent | ) |
Definition at line 68 of file accessmanager.cpp.
| AccessManager::~AccessManager | ( | ) | [virtual] |
Definition at line 73 of file accessmanager.cpp.
Member Function Documentation
| QNetworkReply * AccessManager::createRequest | ( | Operation | op, | |
| const QNetworkRequest & | req, | |||
| QIODevice * | outgoingData = 0 | |||
| ) | [protected, virtual] |
Reimplemented for internal reasons, the API is not affected.
- See also:
- QNetworkAccessManager::createRequest
For internal use only.
Reimplemented from QNetworkAccessManager.
Definition at line 88 of file accessmanager.cpp.
| bool AccessManager::isExternalContentAllowed | ( | ) | const |
Returns true if external content is going to be fetched.
- See also:
- setExternalContentAllowed
Definition at line 83 of file accessmanager.cpp.
| void AccessManager::setExternalContentAllowed | ( | bool | allowed | ) |
Set allowed to false if you don't want any external content to be fetched.
By default external content is fetched.
Definition at line 78 of file accessmanager.cpp.
The documentation for this class was generated from the following files:
KDE 4.4 API Reference