GnuCashew ~ GnuCash Enabled Web
GCW
BaseItem.h
Go to the documentation of this file.
1 #line 2 "src/Dbo/BaseItem.h"
2 
3 #ifndef __DBO_BASEITEM_H___
4 #define __DBO_BASEITEM_H___
5 
6 #include <Wt/Dbo/Dbo.h>
7 
8 namespace GCW {
9 
10 /*!
11 ** \brief Database Object Namespace
12 **
13 ** This namespace is reserved for objects that are used to interface
14 ** to the back-end datasets directly.
15 **
16 ** At present, the Session object is only set up to access sqlite
17 ** data files.
18 **
19 ** The primary gnucash Dbo classes are intended to be direct-maps of
20 ** the sqlite underlying schema.
21 **
22 ** It is possible to have gnucashew modify the existing gnucash schema
23 ** so as to add additional tables and fields, but it is also possible
24 ** to simply have gnucashew keep is customized data in a separate
25 ** database.
26 **
27 ** \ref see: https://wiki.gnucash.org/wiki/SQL
28 **
29 ** \ref see: https://wiki.gnucash.org/wiki/images/8/86/Gnucash_erd.png
30 */
31  namespace Dbo {
32 
33 template <class C>
34  class BaseItem
35 : public Wt::Dbo::Dbo< C >
36 {
37  public:
38 
39  using Ptr = Wt::Dbo::ptr< C >;
40  using Collection = Wt::Dbo::collection< Ptr >;
41  using Vector = std::vector< Ptr >;
42 
43  BaseItem():Wt::Dbo::Dbo<C>() {}
44 
45 }; // endclass BaseItem
46 
47  } // endnamespace Dbo
48 } // endnamespace GCW {
49 
50 #endif // end#ifndef __BASEITEM_H___
51 
52 
Wt::Dbo::collection< Ptr > Collection
Definition: BaseItem.h:40
std::vector< Ptr > Vector
Definition: BaseItem.h:41
Wt::Dbo::ptr< C > Ptr
Definition: BaseItem.h:39
Definition: App.h:17
Definition: GncLock.h:6