KMyMoney Plugin API

appinterface.h
1/*
2 SPDX-FileCopyrightText: 2018 Łukasz Wojniłowicz <lukasz.wojnilowicz@gmail.com>
3 SPDX-License-Identifier: GPL-2.0-or-later
4*/
5
6#ifndef APPINTERFACE_H
7#define APPINTERFACE_H
8
9// ----------------------------------------------------------------------------
10// QT Includes
11
12#include <QObject>
13
14// ----------------------------------------------------------------------------
15// KDE Includes
16
17// ----------------------------------------------------------------------------
18// Project Includes
19
20#include <kmm_plugin_export.h>
21
22class QTimer;
23
24class IMyMoneyOperationsFormat;
25typedef void (*KMyMoneyAppCallback)(int, int, const QString&);
26
27namespace KMyMoneyPlugin {
28class KMM_PLUGIN_EXPORT AppInterface : public QObject
29{
30 Q_OBJECT
31
32public:
33 explicit AppInterface(QObject* parent, const char* name = 0);
34 virtual ~AppInterface();
35
36 /**
37 * Makes sure that a MyMoneyFile is open and has been created successfully.
38 *
39 * @return Whether the file is open and initialised
40 */
41 virtual bool fileOpen() = 0;
42
43 virtual bool isDatabase() = 0;
44 virtual bool isNativeFile() = 0;
45 virtual QUrl filenameURL() const = 0;
46 virtual void writeFilenameURL(const QUrl& url) = 0;
47 virtual QUrl lastOpenedURL() = 0;
48 virtual void writeLastUsedFile(const QString& fileName) = 0;
49 virtual void slotFileOpenRecent(const QUrl& url) = 0;
50 virtual void addToRecentFiles(const QUrl& url) = 0;
51 virtual KMyMoneyAppCallback progressCallback() = 0;
52 virtual void writeLastUsedDir(const QString& directory) = 0;
53 virtual QString readLastUsedDir() const = 0;
54 virtual void consistencyCheck(bool alwaysDisplayResult) = 0;
55
56Q_SIGNALS:
57 void kmmFilePlugin(unsigned int);
58};
59
60}
61
62#endif
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 22 2024 12:03:11 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.