KIMAP2
29class CreateJobPrivate :
public JobPrivate
32 CreateJobPrivate(Session *session,
const QString &name) : JobPrivate(session,
name) { }
33 ~CreateJobPrivate() { }
39using namespace KIMAP2;
41CreateJob::CreateJob(
Session *session)
42 : Job(*new CreateJobPrivate(session,
"Create"))
46CreateJob::~CreateJob()
50void CreateJob::doStart()
53 d->sendCommand(
"CREATE",
'\"' + KIMAP2::encodeImapFolderName(d->mailBox.toUtf8()) +
'\"');
56void CreateJob::handleResponse(
const Message &response)
60 if (!response.content.isEmpty() &&
61 d->tags.contains(response.content.first().toString())) {
62 if (response.content.size() >= 2 &&
63 response.content[1].toString() ==
"NO") {
64 for (
auto it = response.responseCode.cbegin(), end = response.responseCode.cend();
68 if (it->toString() ==
"ALREADYEXISTS") {
70 d->tags.removeAll(response.content.first().toString());
71 if (d->tags.isEmpty()) {
80 handleErrorReplies(response);
QString mailBox() const
The name of the mailbox that will be created.
void setMailBox(const QString &mailBox)
Set the name of the new mailbox.
QString name(const QVariant &location)
This file is part of the IMAP support library and defines the RfcCodecs class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Feb 21 2025 11:56:37 by
doxygen 1.13.2 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.