TraDemGen Logo  1.00.0
C++ Simulated Travel Demand Generation Library
 All Classes Namespaces Files Functions Variables Typedefs Friends Pages
DBManager.hpp
Go to the documentation of this file.
1 #ifndef __TRADEMGEN_CMD_DBMANAGER_HPP
2 #define __TRADEMGEN_CMD_DBMANAGER_HPP
3 
4 // //////////////////////////////////////////////////////////////////////
5 // Import section
6 // //////////////////////////////////////////////////////////////////////
7 // StdAir
8 #include <stdair/stdair_basic_types.hpp>
9 #include <stdair/stdair_db.hpp>
10 // Trademgen
12 
13 namespace TRADEMGEN {
14 
15  // Forward declarations
16  struct AirlineStruct;
17 
20  class DBManager {
21  public:
24  static void updateAirlineInDB (stdair::DBSession_T&,
25  const stdair::AirlineStruct&);
26 
30  static bool retrieveAirline (stdair::DBSession_T&,
31  const stdair::AirlineCode_T&,
32  stdair::AirlineStruct&);
33 
34 
35  public:
37  static void prepareSelectStatement (stdair::DBSession_T&,
38  stdair::DBRequestStatement_T&,
39  stdair::AirlineStruct&);
40 
45  static bool iterateOnStatement (stdair::DBRequestStatement_T&,
46  stdair::AirlineStruct&,
47  const bool iShouldDoReset);
48 
49 
50  private:
52  static void prepareSelectOnAirlineCodeStatement (stdair::DBSession_T&,
53  stdair::DBRequestStatement_T&,
54  const stdair::AirlineCode_T&,
55  stdair::AirlineStruct&);
56 
57 
58  private:
60  DBManager() {}
61  DBManager(const DBManager&) {}
63  ~DBManager() {}
64  };
65 
66 }
67 #endif // __TRADEMGEN_CMD_DBMANAGER_HPP