KIMAP

getquotajob.h
1/*
2 SPDX-FileCopyrightText: 2009 Andras Mantia <amantia@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6
7#pragma once
8
9#include "quotajobbase.h"
10
11namespace KIMAP
12{
13class Session;
14struct Message;
15class GetQuotaJobPrivate;
16
17/**
18 * Gets resource limits for a quota root.
19 *
20 * Quotas are defined with respect to "resources" and "quota roots".
21 * A resource is a numerical property that can be limited, such
22 * as the octet size of all the messages in a mailbox, or the
23 * number of messages in a mailbox. Each mailbox has one or more
24 * quota roots, which are where the resource limits are defined.
25 * A quota root may or may not be a mailbox name, and an empty
26 * string is a valid quota root. All mailboxes with the same quota
27 * root share the resource limits of the quota root.
28 *
29 * This job can only be run when the session is in the
30 * authenticated (or selected) state.
31 *
32 * This job requires that the server supports the QUOTA
33 * capability, defined in
34 * <a href="https://tools.ietf.org/html/rfc2087">RFC 2087</a>.
35 */
36class KIMAP_EXPORT GetQuotaJob : public QuotaJobBase
37{
38 Q_OBJECT
39 Q_DECLARE_PRIVATE(GetQuotaJob)
40
41 friend class SessionPrivate;
42
43public:
44 explicit GetQuotaJob(Session *session);
45 ~GetQuotaJob() override;
46
47 /**
48 * Set the quota root to get the resource limits for.
49 * @param root the quota root to set
50 * @see GetQuotaRootJob
51 */
52 void setRoot(const QByteArray &root);
53 /**
54 * The quota root that resource limit information will be fetched for.
55 */
56 [[nodiscard]] QByteArray root() const;
57
58protected:
59 void doStart() override;
60 void handleResponse(const Response &response) override;
61};
62
63}
Gets resource limits for a quota root.
Definition getquotajob.h:37
Base class for jobs that operate on mailbox quotas.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:14:37 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.