summaryrefslogtreecommitdiffstats
path: root/kmymoney2/mymoney/mymoneybudget.h
diff options
context:
space:
mode:
Diffstat (limited to 'kmymoney2/mymoney/mymoneybudget.h')
-rw-r--r--kmymoney2/mymoney/mymoneybudget.h84
1 files changed, 42 insertions, 42 deletions
diff --git a/kmymoney2/mymoney/mymoneybudget.h b/kmymoney2/mymoney/mymoneybudget.h
index a2eea02..e7e44b4 100644
--- a/kmymoney2/mymoney/mymoneybudget.h
+++ b/kmymoney2/mymoney/mymoneybudget.h
@@ -25,11 +25,11 @@
// ----------------------------------------------------------------------------
// QT Includes
-#include <qmap.h>
-#include <qvaluelist.h>
-#include <qstring.h>
-class QDomElement;
-class QDomDocument;
+#include <tqmap.h>
+#include <tqvaluelist.h>
+#include <tqstring.h>
+class TQDomElement;
+class TQDomDocument;
// ----------------------------------------------------------------------------
// Project Includes
@@ -55,19 +55,19 @@ class KMYMONEY_EXPORT MyMoneyBudget: public MyMoneyObject
public:
MyMoneyBudget(void);
~MyMoneyBudget();
- MyMoneyBudget(const QString& _name);
+ MyMoneyBudget(const TQString& _name);
/**
* This constructor creates an object based on the data found in the
- * QDomElement referenced by @p node. If problems arise, the @p id of
+ * TQDomElement referenced by @p node. If problems arise, the @p id of
* the object is cleared (see MyMoneyObject::clearId()).
*/
- MyMoneyBudget(const QDomElement& node);
+ MyMoneyBudget(const TQDomElement& node);
/**
* This constructor creates an object based on the data found in the
* MyMoneyBudget budget object.
*/
- MyMoneyBudget(const QString& id, const MyMoneyBudget& budget);
+ MyMoneyBudget(const TQString& id, const MyMoneyBudget& budget);
/**
* Helper class for MyMoneyBudget
@@ -80,17 +80,17 @@ public:
{
public:
// get functions
- const QDate& startDate ( void ) const { return m_start; }
+ const TQDate& startDate ( void ) const { return m_start; }
const MyMoneyMoney& amount( void ) const { return m_amount; }
// set functions
- void setStartDate ( const QDate& _start ) { m_start = _start; }
+ void setStartDate ( const TQDate& _start ) { m_start = _start; }
void setAmount( const MyMoneyMoney& _amount ) { m_amount = _amount;}
bool operator == (const PeriodGroup &r) const { return (m_start == r.m_start && m_amount == r.m_amount); }
private:
- QDate m_start;
+ TQDate m_start;
MyMoneyMoney m_amount;
};
@@ -113,23 +113,23 @@ public:
eMax
} eBudgetLevel;
- static const QStringList kBudgetLevelText;
+ static const TQStringList kBudgetLevelText;
public:
AccountGroup() : m_budgetlevel(eNone), m_budgetsubaccounts(false) {}
// get functions
- const QString& id( void ) const { return m_id; }
+ const TQString& id( void ) const { return m_id; }
bool budgetSubaccounts( void ) const { return m_budgetsubaccounts; }
eBudgetLevel budgetLevel( void ) const { return m_budgetlevel; }
- const PeriodGroup& period( const QDate &_date ) const { return m_periods[_date]; }
- const QMap<QDate, PeriodGroup>& getPeriods( void ) const { return m_periods; }
+ const PeriodGroup& period( const TQDate &_date ) const { return m_periods[_date]; }
+ const TQMap<TQDate, PeriodGroup>& getPeriods( void ) const { return m_periods; }
void clearPeriods(void) { m_periods.clear(); }
const MyMoneyMoney balance( void ) const
{
MyMoneyMoney balance;
- QMap<QDate, PeriodGroup>::const_iterator it;
+ TQMap<TQDate, PeriodGroup>::const_iterator it;
for(it = m_periods.begin(); it != m_periods.end(); ++it)
{
balance += (*it).amount();
@@ -151,10 +151,10 @@ public:
}
// set functions
- void setId( QString _id ) { m_id = _id; }
+ void setId( TQString _id ) { m_id = _id; }
void setBudgetLevel( eBudgetLevel _level ) { m_budgetlevel = _level; }
void setBudgetSubaccounts( bool _b ) { m_budgetsubaccounts = _b; }
- void addPeriod( const QDate& _date, PeriodGroup &period ) { m_periods[_date] = period; }
+ void addPeriod( const TQDate& _date, PeriodGroup &period ) { m_periods[_date] = period; }
// This member adds the value of another account group
// m_budgetlevel is adjusted to the larger one of both
@@ -171,11 +171,11 @@ public:
void convertToMonthByMonth(void);
private:
- QString m_id;
+ TQString m_id;
eBudgetLevel m_budgetlevel;
bool m_budgetsubaccounts;
- QMap<QDate, PeriodGroup> m_periods;
+ TQMap<TQDate, PeriodGroup> m_periods;
};
/**
@@ -184,17 +184,17 @@ public:
bool operator == (const MyMoneyBudget &) const;
// Simple get operations
- const QString& name(void) const { return m_name; }
- const QDate& budgetStart(void) const { return m_start; }
- QString id(void) const { return m_id; }
- const AccountGroup & account(const QString _id) const;
- bool contains(const QString _id) const { return m_accounts.contains(_id); }
- QValueList<AccountGroup> getaccounts(void) const { return m_accounts.values(); }
+ const TQString& name(void) const { return m_name; }
+ const TQDate& budgetStart(void) const { return m_start; }
+ TQString id(void) const { return m_id; }
+ const AccountGroup & account(const TQString _id) const;
+ bool tqcontains(const TQString _id) const { return m_accounts.tqcontains(_id); }
+ TQValueList<AccountGroup> getaccounts(void) const { return m_accounts.values(); }
// Simple set operations
- void setName(const QString& _name) { m_name = _name; }
- void setBudgetStart(const QDate& _start);
- void setAccount(const AccountGroup &_account, const QString _id);
+ void setName(const TQString& _name) { m_name = _name; }
+ void setBudgetStart(const TQDate& _start);
+ void setAccount(const AccountGroup &_account, const TQString _id);
/**
* This method writes this Budget to the DOM element @p e,
@@ -204,7 +204,7 @@ public:
* @param doc The document which we can use to create new sub-elements
* if needed
*/
- void write(QDomElement& e, QDomDocument *doc) const;
+ void write(TQDomElement& e, TQDomDocument *doc) const;
/**
* This method reads a Budget from the DOM element @p e, and
@@ -216,17 +216,17 @@ public:
* element @p e. If false is returned, the contents of this Budget
* object are undefined.
*/
- bool read(const QDomElement& e);
+ bool read(const TQDomElement& e);
/**
- * This method creates a QDomElement for the @p document
- * under the parent node @p parent. (This version overwrites the
+ * This method creates a TQDomElement for the @p document
+ * under the tqparent node @p tqparent. (This version overwrites the
* MMObject base class.)
*
- * @param document reference to QDomDocument
- * @param parent reference to QDomElement parent node
+ * @param document reference to TQDomDocument
+ * @param tqparent reference to TQDomElement tqparent node
*/
- virtual void writeXML(QDomDocument& document, QDomElement& parent) const;
+ virtual void writeXML(TQDomDocument& document, TQDomElement& tqparent) const;
/**
* This method checks if a reference to the given object exists. It returns,
@@ -238,31 +238,31 @@ public:
* @retval true This object references object with id @p id.
* @retval false This object does not reference the object with id @p id.
*/
- virtual bool hasReferenceTo(const QString& id) const;
+ virtual bool hasReferenceTo(const TQString& id) const;
/**
* This member removes all references to object identified by @p id. Used
* to remove objects which are about to be removed from the engine.
*/
- void removeReference(const QString& id);
+ void removeReference(const TQString& id);
private:
/**
* The user-assigned name of the Budget
*/
- QString m_name;
+ TQString m_name;
/**
* The user-assigned year of the Budget
*/
- QDate m_start;
+ TQDate m_start;
/**
* Map the budgeted accounts
*
* Each account Id is stored against the AccountGroup information
*/
- QMap<QString, AccountGroup> m_accounts;
+ TQMap<TQString, AccountGroup> m_accounts;
};
#endif // MYMONEYBudget_H