GnuCash  2.6.99
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
gnc-backend-xml.h
Go to the documentation of this file.
1 /********************************************************************
2  * gnc-backend-xml.h: load and save data to XML files *
3  * *
4  * This program is free software; you can redistribute it and/or *
5  * modify it under the terms of the GNU General Public License as *
6  * published by the Free Software Foundation; either version 2 of *
7  * the License, or (at your option) any later version. *
8  * *
9  * This program is distributed in the hope that it will be useful, *
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
12  * GNU General Public License for more details. *
13  * *
14  * You should have received a copy of the GNU General Public License*
15  * along with this program; if not, contact: *
16  * *
17  * Free Software Foundation Voice: +1-617-542-5942 *
18  * 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652 *
19  * Boston, MA 02110-1301, USA [email protected] *
20 \********************************************************************/
31 #ifndef GNC_BACKEND_XML_H_
32 #define GNC_BACKEND_XML_H_
33 
34 #include "qof.h"
35 #include <gmodule.h>
36 
37 #include "qofbackend-p.h"
38 
39 typedef enum
40 {
41  XML_RETAIN_NONE,
42  XML_RETAIN_DAYS,
43  XML_RETAIN_ALL
44 } XMLFileRetentionType;
45 
46 typedef enum
47 {
48  GNC_BOOK_NOT_OURS,
49  GNC_BOOK_BIN_FILE,
50  GNC_BOOK_XML1_FILE,
51  GNC_BOOK_XML2_FILE,
52  GNC_BOOK_XML2_FILE_NO_ENCODING,
53  GNC_BOOK_POST_XML2_0_0_FILE
54 } QofBookFileType;
55 
57 {
58  QofBackend be;
59 
60  char *dirname;
61  char *fullpath; /* Fully qualified path to book */
62  char *lockfile;
63  char *linkfile;
64  int lockfd;
65 
66  QofBook *book; /* The primary, main open book */
67 };
68 
69 typedef struct FileBackend_struct FileBackend;
70 
71 // This is now a static inside the module
72 //QofBackend * libgncmod_backend_file_LTX_gnc_backend_new(void);
73 
77 
78 #ifndef GNC_NO_LOADABLE_MODULES
79 
83 G_MODULE_EXPORT
84 void qof_backend_module_init(void);
85 #endif
86 
87 #endif /* GNC_BACKEND_XML_H_ */
void gnc_module_init_backend_xml(void)
G_MODULE_EXPORT void qof_backend_module_init(void)
private api for data storage backend