Details
-
Task
-
Resolution: Unresolved
-
P2: Important
-
None
-
None
-
None
-
13
-
Foundation PM Staging
Description
One of the last issues with QCryptographicHash is that the common operation of hex- or base64-encoding the result lets users pick the QByteArray-returning functions (result() and hash() instead of resultView() and hashInto(), just to be able to call toHex() or toBase64() on them, conveniently.
Putting these operations onto QByteArrayView doesn't solve the problem, since it will have to return by QByteArray, bringing back the allocation we wanted to save. Lack of a lower-level API to perform these operations, paired with various options that come on top of the basic transformation, mean a simple enum Encoding
{Hex, Base64, Percent}will probably not cut it, either.
So this ticket is more of a reminder that we need to design something first.
Attachments
Issue Links
- resulted from
-
QTBUG-125431 Add QCryptographicHash::hashInto(QSpan<std::byte>)
- Closed