mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Merge the xml parsers of business objects into the main xml backend module.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@19361 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
4bd4d41c05
commit
d35b135447
@ -23,15 +23,26 @@ GNC_ADD_SWIG_COMMAND (${SWIG_GNC_MODULE_C} ${CMAKE_CURRENT_SOURCE_DIR}/gnc-modul
|
|||||||
|
|
||||||
SET (libgnc_backend_xml_SOURCES
|
SET (libgnc_backend_xml_SOURCES
|
||||||
gnc-account-xml-v2.c
|
gnc-account-xml-v2.c
|
||||||
|
gnc-address-xml-v2.c
|
||||||
|
gnc-bill-term-xml-v2.c
|
||||||
gnc-book-xml-v2.c
|
gnc-book-xml-v2.c
|
||||||
gnc-budget-xml-v2.c
|
gnc-budget-xml-v2.c
|
||||||
gnc-commodity-xml-v2.c
|
gnc-commodity-xml-v2.c
|
||||||
|
gnc-customer-xml-v2.c
|
||||||
|
gnc-employee-xml-v2.c
|
||||||
|
gnc-entry-xml-v2.c
|
||||||
gnc-freqspec-xml-v2.c
|
gnc-freqspec-xml-v2.c
|
||||||
|
gnc-invoice-xml-v2.c
|
||||||
|
gnc-job-xml-v2.c
|
||||||
gnc-lot-xml-v2.c
|
gnc-lot-xml-v2.c
|
||||||
|
gnc-order-xml-v2.c
|
||||||
|
gnc-owner-xml-v2.c
|
||||||
gnc-pricedb-xml-v2.c
|
gnc-pricedb-xml-v2.c
|
||||||
gnc-recurrence-xml-v2.c
|
gnc-recurrence-xml-v2.c
|
||||||
gnc-schedxaction-xml-v2.c
|
gnc-schedxaction-xml-v2.c
|
||||||
|
gnc-tax-table-xml-v2.c
|
||||||
gnc-transaction-xml-v2.c
|
gnc-transaction-xml-v2.c
|
||||||
|
gnc-vendor-xml-v2.c
|
||||||
io-example-account.c
|
io-example-account.c
|
||||||
io-gncxml-gen.c
|
io-gncxml-gen.c
|
||||||
io-gncxml-v1.c
|
io-gncxml-v1.c
|
||||||
|
@ -20,15 +20,26 @@ AM_CPPFLAGS = \
|
|||||||
|
|
||||||
libgnc_backend_xml_utils_la_SOURCES = \
|
libgnc_backend_xml_utils_la_SOURCES = \
|
||||||
gnc-account-xml-v2.c \
|
gnc-account-xml-v2.c \
|
||||||
|
gnc-address-xml-v2.c \
|
||||||
|
gnc-bill-term-xml-v2.c \
|
||||||
gnc-book-xml-v2.c \
|
gnc-book-xml-v2.c \
|
||||||
gnc-budget-xml-v2.c \
|
gnc-budget-xml-v2.c \
|
||||||
gnc-commodity-xml-v2.c \
|
gnc-commodity-xml-v2.c \
|
||||||
|
gnc-customer-xml-v2.c \
|
||||||
|
gnc-employee-xml-v2.c \
|
||||||
|
gnc-entry-xml-v2.c \
|
||||||
gnc-freqspec-xml-v2.c \
|
gnc-freqspec-xml-v2.c \
|
||||||
|
gnc-invoice-xml-v2.c \
|
||||||
|
gnc-job-xml-v2.c \
|
||||||
gnc-lot-xml-v2.c \
|
gnc-lot-xml-v2.c \
|
||||||
|
gnc-order-xml-v2.c \
|
||||||
|
gnc-owner-xml-v2.c \
|
||||||
gnc-pricedb-xml-v2.c \
|
gnc-pricedb-xml-v2.c \
|
||||||
gnc-recurrence-xml-v2.c \
|
gnc-recurrence-xml-v2.c \
|
||||||
gnc-schedxaction-xml-v2.c \
|
gnc-schedxaction-xml-v2.c \
|
||||||
|
gnc-tax-table-xml-v2.c \
|
||||||
gnc-transaction-xml-v2.c \
|
gnc-transaction-xml-v2.c \
|
||||||
|
gnc-vendor-xml-v2.c \
|
||||||
io-example-account.c \
|
io-example-account.c \
|
||||||
io-gncxml-gen.c \
|
io-gncxml-gen.c \
|
||||||
io-gncxml-v1.c \
|
io-gncxml-v1.c \
|
||||||
@ -47,18 +58,30 @@ libgncmod_backend_xml_la_SOURCES = \
|
|||||||
noinst_HEADERS = \
|
noinst_HEADERS = \
|
||||||
gnc-backend-xml.h \
|
gnc-backend-xml.h \
|
||||||
gnc-xml.h \
|
gnc-xml.h \
|
||||||
|
gnc-address-xml-v2.h \
|
||||||
|
gnc-bill-term-xml-v2.h \
|
||||||
|
gnc-customer-xml-v2.h \
|
||||||
|
gnc-employee-xml-v2.h \
|
||||||
|
gnc-entry-xml-v2.h \
|
||||||
|
gnc-invoice-xml-v2.h \
|
||||||
|
gnc-job-xml-v2.h \
|
||||||
|
gnc-order-xml-v2.h \
|
||||||
|
gnc-owner-xml-v2.h \
|
||||||
|
gnc-tax-table-xml-v2.h \
|
||||||
|
gnc-vendor-xml-v2.h \
|
||||||
gnc-xml-helper.h \
|
gnc-xml-helper.h \
|
||||||
io-example-account.h \
|
io-example-account.h \
|
||||||
io-gncxml-gen.h \
|
io-gncxml-gen.h \
|
||||||
io-gncxml.h \
|
|
||||||
io-gncxml-v2.h \
|
io-gncxml-v2.h \
|
||||||
|
io-gncxml.h \
|
||||||
io-utils.h \
|
io-utils.h \
|
||||||
sixtp-dom-generators.h \
|
sixtp-dom-generators.h \
|
||||||
sixtp-dom-parsers.h \
|
sixtp-dom-parsers.h \
|
||||||
sixtp.h \
|
|
||||||
sixtp-parsers.h \
|
sixtp-parsers.h \
|
||||||
sixtp-stack.h \
|
sixtp-stack.h \
|
||||||
sixtp-utils.h
|
sixtp-utils.h \
|
||||||
|
sixtp.h \
|
||||||
|
xml-helpers.h
|
||||||
|
|
||||||
libgnc_backend_xml_utils_la_LIBADD = \
|
libgnc_backend_xml_utils_la_LIBADD = \
|
||||||
${GLIB_LIBS} \
|
${GLIB_LIBS} \
|
||||||
|
@ -76,6 +76,18 @@ typedef int ssize_t;
|
|||||||
#include "gnc-backend-xml.h"
|
#include "gnc-backend-xml.h"
|
||||||
#include "gnc-gconf-utils.h"
|
#include "gnc-gconf-utils.h"
|
||||||
|
|
||||||
|
#include "gnc-address-xml-v2.h"
|
||||||
|
#include "gnc-bill-term-xml-v2.h"
|
||||||
|
#include "gnc-customer-xml-v2.h"
|
||||||
|
#include "gnc-employee-xml-v2.h"
|
||||||
|
#include "gnc-entry-xml-v2.h"
|
||||||
|
#include "gnc-invoice-xml-v2.h"
|
||||||
|
#include "gnc-job-xml-v2.h"
|
||||||
|
#include "gnc-order-xml-v2.h"
|
||||||
|
#include "gnc-owner-xml-v2.h"
|
||||||
|
#include "gnc-tax-table-xml-v2.h"
|
||||||
|
#include "gnc-vendor-xml-v2.h"
|
||||||
|
|
||||||
#ifndef HAVE_STRPTIME
|
#ifndef HAVE_STRPTIME
|
||||||
# include "strptime.h"
|
# include "strptime.h"
|
||||||
#endif
|
#endif
|
||||||
@ -1216,6 +1228,23 @@ gnc_backend_new(void)
|
|||||||
return be;
|
return be;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
business_core_xml_init(void)
|
||||||
|
{
|
||||||
|
/* Initialize our pointers into the backend subsystem */
|
||||||
|
gnc_address_xml_initialize ();
|
||||||
|
gnc_billterm_xml_initialize ();
|
||||||
|
gnc_customer_xml_initialize ();
|
||||||
|
gnc_employee_xml_initialize ();
|
||||||
|
gnc_entry_xml_initialize ();
|
||||||
|
gnc_invoice_xml_initialize ();
|
||||||
|
gnc_job_xml_initialize ();
|
||||||
|
gnc_order_xml_initialize ();
|
||||||
|
gnc_owner_xml_initialize ();
|
||||||
|
gnc_taxtable_xml_initialize ();
|
||||||
|
gnc_vendor_xml_initialize ();
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
gnc_provider_free (QofBackendProvider *prov)
|
gnc_provider_free (QofBackendProvider *prov)
|
||||||
{
|
{
|
||||||
@ -1253,6 +1282,9 @@ gnc_module_init_backend_xml(void)
|
|||||||
prov->provider_free = gnc_provider_free;
|
prov->provider_free = gnc_provider_free;
|
||||||
prov->check_data_type = gnc_determine_file_type;
|
prov->check_data_type = gnc_determine_file_type;
|
||||||
qof_backend_register_provider (prov);
|
qof_backend_register_provider (prov);
|
||||||
|
|
||||||
|
/* And the business objects */
|
||||||
|
business_core_xml_init();
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ========================== END OF FILE ===================== */
|
/* ========================== END OF FILE ===================== */
|
||||||
|
@ -1,48 +0,0 @@
|
|||||||
# CMakeLists.txt for src/business/business-code
|
|
||||||
|
|
||||||
ADD_DEFINITIONS (-DG_LOG_DOMAIN=\"gnc.business.core\")
|
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES (${GLIB2_INCLUDE_DIRS})
|
|
||||||
INCLUDE_DIRECTORIES (${GCONF2_INCLUDE_DIRS})
|
|
||||||
INCLUDE_DIRECTORIES (${LIBINTL_INCLUDE_PATH})
|
|
||||||
INCLUDE_DIRECTORIES (${REGEX_INCLUDE_PATH})
|
|
||||||
INCLUDE_DIRECTORIES (${GUILE_INCLUDE_DIRS})
|
|
||||||
INCLUDE_DIRECTORIES (${LIBXML2_INCLUDE_DIR})
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_BINARY_DIR}/src ) # for config.h
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_SOURCE_DIR}/src ) # for gnc-ui.h
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_SOURCE_DIR}/src/gnc-module )
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_SOURCE_DIR}/src/engine )
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_SOURCE_DIR}/src/libqof/qof) # for qof.h
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_BINARY_DIR}/src/engine) # for swig-runtime.h
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_SOURCE_DIR}/src/backend/xml) # for io-gncxml-v2.h
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_CURRENT_SOURCE_DIR}) # when building swig-core-utils.c
|
|
||||||
INCLUDE_DIRECTORIES (${CMAKE_CURRENT_BINARY_DIR}) # for gncla-dir.h
|
|
||||||
|
|
||||||
SET (libgnc_business_core_SOURCES
|
|
||||||
gncmod-business-core.c
|
|
||||||
)
|
|
||||||
|
|
||||||
SET (libgnc_business_core_xml_SOURCES
|
|
||||||
xml/gnc-address-xml-v2.c
|
|
||||||
xml/gnc-bill-term-xml-v2.c
|
|
||||||
xml/gnc-customer-xml-v2.c
|
|
||||||
xml/gnc-employee-xml-v2.c
|
|
||||||
xml/gnc-entry-xml-v2.c
|
|
||||||
xml/gnc-invoice-xml-v2.c
|
|
||||||
xml/gnc-job-xml-v2.c
|
|
||||||
xml/gnc-order-xml-v2.c
|
|
||||||
xml/gnc-owner-xml-v2.c
|
|
||||||
xml/gnc-tax-table-xml-v2.c
|
|
||||||
xml/gnc-vendor-xml-v2.c
|
|
||||||
xml/gncmod-business-backend-xml.c
|
|
||||||
)
|
|
||||||
|
|
||||||
SET (libgnc_business_core_HEADERS
|
|
||||||
)
|
|
||||||
|
|
||||||
ADD_LIBRARY (business-core
|
|
||||||
${libgnc_business_core_SOURCES}
|
|
||||||
${libgnc_business_core_HEADERS}
|
|
||||||
${libgnc_business_core_xml_SOURCES}
|
|
||||||
)
|
|
||||||
|
|
@ -13,34 +13,9 @@ AM_CPPFLAGS = \
|
|||||||
${LIBXML2_CFLAGS} \
|
${LIBXML2_CFLAGS} \
|
||||||
${GLIB_CFLAGS}
|
${GLIB_CFLAGS}
|
||||||
|
|
||||||
libgncmod_business_backend_xml_la_SOURCES = \
|
libgncmod_business_backend_xml_la_SOURCES =
|
||||||
gncmod-business-backend-xml.c \
|
|
||||||
gnc-address-xml-v2.c \
|
|
||||||
gnc-bill-term-xml-v2.c \
|
|
||||||
gnc-customer-xml-v2.c \
|
|
||||||
gnc-employee-xml-v2.c \
|
|
||||||
gnc-entry-xml-v2.c \
|
|
||||||
gnc-invoice-xml-v2.c \
|
|
||||||
gnc-job-xml-v2.c \
|
|
||||||
gnc-order-xml-v2.c \
|
|
||||||
gnc-owner-xml-v2.c \
|
|
||||||
gnc-tax-table-xml-v2.c \
|
|
||||||
gnc-vendor-xml-v2.c
|
|
||||||
|
|
||||||
noinst_HEADERS = \
|
noinst_HEADERS =
|
||||||
gncmod-business-backend-xml.h \
|
|
||||||
gnc-address-xml-v2.h \
|
|
||||||
gnc-bill-term-xml-v2.h \
|
|
||||||
gnc-customer-xml-v2.h \
|
|
||||||
gnc-employee-xml-v2.h \
|
|
||||||
gnc-entry-xml-v2.h \
|
|
||||||
gnc-invoice-xml-v2.h \
|
|
||||||
gnc-job-xml-v2.h \
|
|
||||||
gnc-order-xml-v2.h \
|
|
||||||
gnc-owner-xml-v2.h \
|
|
||||||
gnc-tax-table-xml-v2.h \
|
|
||||||
gnc-vendor-xml-v2.h \
|
|
||||||
xml-helpers.h
|
|
||||||
|
|
||||||
libgncmod_business_backend_xml_la_LDFLAGS = -module -avoid-version
|
libgncmod_business_backend_xml_la_LDFLAGS = -module -avoid-version
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user