PDA

View Full Version : Monitor requests with QNetworkAccessManager



midas643
8th April 2016, 17:10
Is this possible to capture requests sent with QNetworkAccessManager by default ? Basically what I want it a SIGNAL that is emmited after user does lets say
QNetworkAccessManager::post and retrieve post data. I know I can do this myself but I'm just wondering if such thing is already implemented. There is
QNetworkReply::operation() but it just returns type. And QNetworkRequest doesn't store contents.

anda_skoa
8th April 2016, 21:27
You could probably implement at QNetworkProxyFactory, set it as the application-wide factory and for each request just return a QNetworkProxy::DefaultProxy for every request.

Not sure though is the factory's query method is called for every access to an URL or only for each URL once.

Cheers,
_