expense.h
00001 #ifndef _KPILOT_EXPENSE_H
00002 #define _KPILOT_EXPENSE_H
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032 #include "plugin.h"
00033
00034 class QTextStream;
00035 class QFile;
00036
00037 class Expense;
00038
00039 class PilotRecord;
00040 class PilotDatabase;
00041
00042
00043
00044 class ExpenseConduit : public ConduitAction
00045 {
00046 Q_OBJECT
00047
00048 public:
00049
00050
00051
00052
00053
00054
00055
00056
00057 ExpenseConduit(KPilotDeviceLink *,
00058 const char *name=0L,
00059 const QStringList &args = QStringList());
00060 virtual ~ExpenseConduit();
00061
00062
00063 protected:
00064 virtual bool exec();
00065
00066 protected:
00071 PilotDatabase *fDatabase;
00072
00078 QFile *fCSVFile;
00079 QTextStream *fCSVStream;
00080
00085 int fDBType;
00086 QString fDBnm,fDBsrv,fDBtable,fDBlogin,fDBpasswd;
00087 int fRecordCount;
00088
00092 void doTest();
00093
00099 void csvOutput(QTextStream *,Expense *);
00100 void postgresOutput(Expense *);
00101
00102 protected slots:
00108 void slotNextRecord();
00109
00110 private:
00115 void dumpPostgresTable();
00116
00121 void cleanup();
00122 };
00123
00124 #endif
This file is part of the documentation for kpilot Library Version 3.2.2.