File indexing completed on 2024-04-14 03:55:48
0001 /* 0002 SPDX-FileCopyrightText: KDE Developers 0003 0004 SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 #ifndef KATEVI_HISTORY_H 0008 #define KATEVI_HISTORY_H 0009 0010 #include <QStringList> 0011 #include <ktexteditor_export.h> 0012 0013 namespace KateVi 0014 { 0015 class History 0016 { 0017 public: 0018 explicit History() = default; 0019 ~History() = default; 0020 0021 KTEXTEDITOR_EXPORT void append(const QString &historyItem); 0022 inline const QStringList &items() const 0023 { 0024 return m_items; 0025 } 0026 KTEXTEDITOR_EXPORT void clear(); 0027 inline bool isEmpty() 0028 { 0029 return m_items.isEmpty(); 0030 } 0031 0032 private: 0033 QStringList m_items; 0034 }; 0035 } 0036 0037 #endif // KATEVI_HISTORY_H