KMyMoneyPlugin::ImporterPlugin
#include <kmymoneyplugin.h>
Public Member Functions | |
virtual QStringList | formatMimeTypes () const =0 |
virtual bool | import (const QString &filename)=0 |
virtual bool | isMyFormat (const QString &filename) const |
virtual QString | lastError () const =0 |
Detailed Description
This class describes the interface between the KMyMoney application and it's IMPORTER plugins.
All importer plugins must provide this interface.
A good tutorial on how to design and develop a plugin structure for a KDE application (e.g. KMyMoney) can be found at http://web.archive.org/web/20100305214125/http://developer.kde.org/documentation/tutorials/developing-a-plugin-structure/index.html
Definition at line 234 of file kmymoneyplugin.h.
Constructor & Destructor Documentation
◆ ImporterPlugin()
KMyMoneyPlugin::ImporterPlugin::ImporterPlugin | ( | ) |
Definition at line 114 of file kmymoneyplugin.cpp.
◆ ~ImporterPlugin()
|
virtual |
Definition at line 133 of file kmymoneyplugin.cpp.
Member Function Documentation
◆ formatMimeTypes()
|
pure virtual |
This method returns the list of the MIME types that this plugin handles, e.g.
{"application/x-ofx", "application/x-qfx"}. Be specific: don't use generic types, like "text/plain", which many other types inherit from, and which would result in isMyFormat() returning false positives.
- Returns
- QStringList List of MIME types
◆ import()
|
pure virtual |
Import a file.
- Parameters
-
filename File to import
- Returns
- bool Whether the import was successful.
◆ isMyFormat()
|
virtual |
This method checks whether the file provided is of expected format.
The default implementation checks whether the file's MIME type inherits any of the types provided by formatMimeTypes().
- Parameters
-
filename Fully-qualified pathname to a file
- Returns
- bool Whether the indicated file is importable by this plugin
Definition at line 118 of file kmymoneyplugin.cpp.
◆ lastError()
|
pure virtual |
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 29 2024 11:48:50 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.