/[H6]/PostgresLayer.h
ViewVC logotype

Contents of /PostgresLayer.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 43 - (show annotations) (download)
Wed Sep 6 18:40:35 2006 UTC (17 years, 6 months ago) by torben
File MIME type: text/plain
File size: 1212 byte(s)
Added support for PostgreSQL
1 /*
2 * Primary developers: Hedin & Kevin
3 */
4
5 #pragma once
6
7 #include "DatabaseLayer.h"
8 #include "Containers.h"
9 #include <vector>
10
11 using namespace std;
12
13 class PostgresLayer : public DatabaseLayer
14 {
15 private:
16 CDatabase db;
17
18 public:
19 PostgresLayer(void);
20 ~PostgresLayer(void);
21
22 vector<Person> GetPersonAll(void);
23 Person GetPerson(CString wantInits);
24
25 bool AddPerson(Person NewPerson);
26 bool UpdatePerson(Person ChangePerson);
27 bool DeletePerson(Person RemovePerson);
28 bool ReturnEquipment(CString barcode);
29 bool CheckoutEquipment(Person CheckPersID, Equipment CheckEquip, int Numdays);
30 bool EquipmentReservation(CString barcode, Person CheckPerson);
31 bool UpdateEquipment(Equipment CheckEquip);
32 bool AddEquipment(Equipment AddEquip);
33 vector<Equipment> GetEquipmentAll(void);
34 Equipment GetEquipment(CString wantBarcode);
35 bool DeleteEquipment(Equipment DelEquip);
36 vector<Equipment> Search(CString barcode, CString name, CString inits, bool available, bool reserved, bool deposited);
37 void checkReservations(CString barcode);
38 bool DeleteReservation(CString barcode, CString resid);
39
40 private:
41 void FillEquipmentVector(vector<Equipment> &buffer, CRecordset &rs);
42 };

  ViewVC Help
Powered by ViewVC 1.1.20