28 lines
619 B
C++
28 lines
619 B
C++
#ifndef CCONTACTREPOSITORY_H
|
|
#define CCONTACTREPOSITORY_H
|
|
|
|
#include "Contact.h"
|
|
#include <QList>
|
|
|
|
|
|
class CContactRepository
|
|
{
|
|
public:
|
|
CContactRepository();
|
|
|
|
// int LoadContacts();
|
|
// int SaveContacts();
|
|
int SetContacts(QList<CContact> *ContactsList);
|
|
int AddContact(CContact Contact);
|
|
QList<CContact> *GetContacts(){return &mContactsList;}
|
|
int GetContact(int index, CContact &Contact);
|
|
CContact *GetContactPtr(int index);
|
|
CContact *FindContact(QString ContactRawNumber);
|
|
int DeleteContact(int index);
|
|
|
|
private:
|
|
QList<CContact> mContactsList;
|
|
};
|
|
|
|
#endif // CCONTACTREPOSITORY_H
|