Details
-
Suggestion
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
6.4
-
None
Description
Accessing and parsing the datetime contained in an HTTP header of a QNetworkReply is difficult. It is done automatically for the cooked headers LastModifiedHeader and IfModifiedSinceHeader using the hidden implementation in the method fromHttpDate() of the private class QNetworkHeadersPrivate. But for headers that are not part of the set of known headers, like Date, all we get is access to the values' byte arrays. Since the aforementioned function is not part of the public API, I may not use it and would have to reimplement/copy it to get robust access to the value of the header.
Please provide either a cooked version of the Date HTTP header or a way to use QNetworkHeadersPrivate::fromHttpDate(), for example by adding a function QNetworkReply::datetimeHeader() or something along those lines.