KExportDlg Class Reference

A class to select user data required to export a specified account to the popular QIF format. More...

#include <kexportdlg.h>

Inheritance diagram for KExportDlg:

KExportDlgDecl QDialog
Collaboration diagram for KExportDlg:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 KExportDlg (QWidget *parent)
 ~KExportDlg ()
const QString filename (void) const
QString accountId (void) const
const QString profile (void) const
const QDate startDate (void) const
const QDate endDate (void) const
bool accountSelected (void) const
bool categorySelected (void) const

Protected Slots

void slotOkClicked ()
void slotBrowse ()
void slotNewProfile (void)
void checkData (const QString &account=QString())

Private Member Functions

void readConfig (void)
void writeConfig (void)
void loadProfiles (const bool selectLast=false)
void loadAccounts (void)

Private Attributes

QString m_lastAccount


Detailed Description

This class is used to select the required user input to export a specified account to the popular QIF format. It relies upon the QIF file handling routines in MyMoneyQifProfile and MyMoneyQifWriter to do the actual writing of QIF files.

It uses the global KConfig object to read and write the application settings.

See also:
MyMoneyAccount, MyMoneyQifProfile, MyMoneyQifProfileEditor
Author:
Felix Rodriguez, Michael Edwardes, Thomas Baumgart 2000-2003

Constructor & Destructor Documentation

KExportDlg::KExportDlg ( QWidget parent  ) 

KExportDlg::~KExportDlg (  ) 


Member Function Documentation

const QString KExportDlg::filename ( void   )  const [inline]

This method returns the filename entered into the edit field

Returns:
QString with filename

QString KExportDlg::accountId ( void   )  const

This method returns the account id that has been selected for export

Returns:
QString with account id

const QString KExportDlg::profile ( void   )  const [inline]

This method returns the name of the profile that has been selected for the export operation

Returns:
QString with profile name

const QDate KExportDlg::startDate ( void   )  const [inline]

This method returns the start date of the export dialog

const QDate KExportDlg::endDate ( void   )  const [inline]

This method returns the end date of the export dialog

bool KExportDlg::accountSelected ( void   )  const [inline]

This method returns the state of the account checkbox

bool KExportDlg::categorySelected ( void   )  const [inline]

This method returns the state of the account checkbox

void KExportDlg::slotOkClicked (  )  [protected, slot]

Called when the user clicked on the OK button

void KExportDlg::slotBrowse (  )  [protected, slot]

Called when the user needs to browse the filesystem for a QIF file

void KExportDlg::slotNewProfile ( void   )  [protected, slot]

Called when the user needs a new profile

void KExportDlg::checkData ( const QString &  account = QString()  )  [protected, slot]

This slot checks whether all data is correct to enable the 'Export' button. The enable state of the 'Export' button is updated appropriately.

If the parameter account is not empty, then it is assumed a new account is selected and the date fields will be loaded with the date of the first and last transaction within this account.

Parameters:
account The id of the selected account.

void KExportDlg::readConfig ( void   )  [private]

void KExportDlg::writeConfig ( void   )  [private]

void KExportDlg::loadProfiles ( const bool  selectLast = false  )  [private]

This method loads the available profiles into the combo box. The parameter selectLast controls if the last profile used is preset or not. If preset is not selected, the current selection remains. If the currently selected text is not present in the list anymore, the first item will be selected.

Parameters:
selectLast If true, the last used profile is selected. The default is false.

void KExportDlg::loadAccounts ( void   )  [private]

This method is used to load the available accounts into the combo box for selection.


Member Data Documentation

QString KExportDlg::m_lastAccount [private]

This method is used to load an account hierarchy into a string list

Parameters:
strList Reference to the string list to setup
id Account id to add
leadIn constant leadin to be added in front of the account name This method is used to return the account id of a given account name
account name of the account
Returns:
the ID of the account will be returned. See MyMoneyFile::nameToAccount() for details.


The documentation for this class was generated from the following file:

Generated on Wed Jan 26 13:07:18 2011 for KMyMoney by  doxygen 1.5.6