Messagelib

attachmentstrategy.h
1 /* -*- c++ -*-
2  attachmentstrategy.h
3 
4  This file is part of KMail, the KDE mail client.
5  SPDX-FileCopyrightText: 2003 Marc Mutz <[email protected]>
6  SPDX-FileCopyrightText: 2009 Klarälvdalens Datakonsult AB, a KDAB Group company, [email protected]
7  SPDX-FileCopyrightText: 2009 Andras Mantia <[email protected]>
8 
9  SPDX-License-Identifier: GPL-2.0-or-later
10 */
11 
12 #pragma once
13 
14 #include "messageviewer_export.h"
15 
16 class QString;
17 namespace KMime
18 {
19 class Content;
20 }
21 
22 namespace MessageViewer
23 {
24 /**
25  * @brief The AttachmentStrategy class
26  */
27 class MESSAGEVIEWER_EXPORT AttachmentStrategy
28 {
29 protected:
31  virtual ~AttachmentStrategy();
32 
33 public:
34  //
35  // Factory methods:
36  //
37  enum Type { Iconic, Smart, Inlined, Hidden, HeaderOnly };
38 
39  static const AttachmentStrategy *create(Type type);
40  static const AttachmentStrategy *create(const QString &type);
41 
42  static const AttachmentStrategy *iconic();
43  static const AttachmentStrategy *smart();
44  static const AttachmentStrategy *inlined();
45  static const AttachmentStrategy *hidden();
46  static const AttachmentStrategy *headerOnly();
47 
48  //
49  // Navigation methods:
50  //
51 
52  virtual const char *name() const = 0;
53 
54  //
55  // Behavioral:
56  //
57 
58  enum Display { None, AsIcon, Inline };
59 
60  virtual bool inlineNestedMessages() const = 0;
61  virtual Display defaultDisplay(KMime::Content *node) const = 0;
62  virtual bool requiresAttachmentListInHeader() const;
63 };
64 }
65 
const QLatin1String name
PartitionTable::TableType type
The AttachmentStrategy class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Sun Dec 5 2021 23:04:53 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.