KTransactionPtrVector Class Reference

#include <kpayeesview.h>

Inheritance diagram for KTransactionPtrVector:

QPtrVector
Collaboration diagram for KTransactionPtrVector:

Collaboration graph
[legend]

List of all members.

Public Types

enum  TransactionSortE {
  SortEntryDate = 0, SortPostDate, SortTypeNr, SortReceiver,
  SortValue, SortNr, SortEntryOrder
}

Public Member Functions

 KTransactionPtrVector ()
 ~KTransactionPtrVector ()
void setSortType (const TransactionSortE type)
TransactionSortE sortType (void) const
void setAccountId (const QString &id)
void setPayeeId (const QString &id)

Protected Member Functions

int compareItems (KTransactionPtrVector::Item d1, KTransactionPtrVector::Item d2)

Private Types

enum  { AccountMode = 0, PayeeMode }

Private Member Functions

int compareItems (const QString &s1, const QString &s2) const

Private Attributes

short m_idMode
QString m_id
TransactionSortE m_sortType


Detailed Description

Author:
Michael Edwardes, Thomas Baumgart This class is used to store a sorted vector of pointers to the transactions that are visible in a ledger view. When the vector is created, the sort method is set to SortPostDate. The sort type can be changed using the method setSortType().

Member Enumeration Documentation

This enumerator defines the possible sort methods. Possible values are:

Enumerator:
SortEntryDate  Sort the vector so that the transactions appear sorted according to their entry date
SortPostDate  Sort the vector so that the transactions appear sorted according to their post date
SortTypeNr  Sort the vector so that the transactions appear sorted according to their action and nr
SortReceiver  Sort the vector so that the transactions appear sorted according to their receiver
SortValue  Sort the vector so that the transactions appear sorted according to their value
SortNr  Sort the vector so that the transactions appear sorted according to nr field contents
SortEntryOrder  Sort the vector so that the transactions appear sorted according to order of entry

anonymous enum [private]

Enumerator:
AccountMode 
PayeeMode 


Constructor & Destructor Documentation

KTransactionPtrVector::KTransactionPtrVector (  )  [inline]

KTransactionPtrVector::~KTransactionPtrVector (  )  [inline]


Member Function Documentation

void KTransactionPtrVector::setSortType ( const TransactionSortE  type  ) 

This method is used to set a different sort type. The vector is resorted. See KTransactionPtrVector::TransactionSortE for possible values.

TransactionSortE KTransactionPtrVector::sortType ( void   )  const [inline]

This method returns the current sort type.

Returns:
transactionSortE value of sort order. See KTransactionPtrVector::TransactionSortE for possible values.

void KTransactionPtrVector::setAccountId ( const QString &  id  ) 

This method is used to set the account id to have a chance to get information about the split referencing the current account during the sort phase.

void KTransactionPtrVector::setPayeeId ( const QString &  id  ) 

This method is used to set the payee id to have a chance to get information about the split referencing the current payee during the sort phase.

int KTransactionPtrVector::compareItems ( KTransactionPtrVector::Item  d1,
KTransactionPtrVector::Item  d2 
) [protected]

int KTransactionPtrVector::compareItems ( const QString &  s1,
const QString &  s2 
) const [private]


Member Data Documentation

QString KTransactionPtrVector::m_id [private]


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

Generated on Wed Jan 26 13:09:08 2011 for KMyMoney by  doxygen 1.5.6