Attica
postfiledata.cpp
79 qCDebug(ATTICA) << "PostFileData::addFile: should not add data after calling request() or data()";
86void PostFileData::addFile(const QString &fileName, const QByteArray &file, const QString &mimeType, const QString &fieldName)
96 data.append("\"; filename=\"" + fileName.toUtf8() + "\"\r\nContent-Type: " + mimeType.toLatin1() + "\r\n\r\n");
109 request.setHeader(QNetworkRequest::ContentTypeHeader, QByteArray("multipart/form-data; boundary=" + d->boundary));
KCALUTILS_EXPORT QString mimeType()
KCOREADDONS_EXPORT QString randomString(int length)
ContentTypeHeader
void setHeader(KnownHeaders header, const QVariant &value)
void setUrl(const QUrl &url)
QRandomGenerator * global()
void resize(qsizetype newSize, QChar fillChar)
QByteArray toLatin1() const const
QByteArray toUtf8() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:17:36 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:17:36 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.