
Procedure for Interfacing with Other C and C++ XML Parser Libraries
As mentioned previously, the Expat XML Parser library is the default XML parser library implementation used for decoding XER messages. It is also possible to use the C++ SAX handlers generated by ASN1C with other XML parser library implementations. The XER Run-Time Library (ASN1XER) provides a common interface to other parsers via a common adapter interface layer. There is a special XML interface object file for each of the following supported XML parsers:
- RTXMLLIBXML2IF - interface to LIBXML2;
- RTXMLMSXMLIF - interface to MSXML;
- RTXMLXERCESIF - interface to XERCES;
- RTXMLEXPATIF - interface to EXPAT.
The XER Run-Time Library is completely independent from the XML readers because the adapter layer within these libraries defines a common SAX API.
If an application is linked statically then the static variant of one of these interface objects (their names have suffix "_A") should be linked cooperatively with the XML parser, ASN1XER and ASN1RT libraries.
If the application is linked dynamically (using dynamically-linked libraries (DLL) in Windows or shared objects (SO or SL in UNIX/Linux) then it is necessary to link the application with the dynamic variant of the interfaces (without suffix "_A"), dynamic version of the XML parser, ASN1XER and ASN1RT dynamic libraries.
Objective Systems, Inc.55 Dowlin Forge RoadExton, Pennsylvania 19341 http://www.obj-sys.com Phone: (484) 875-9841 Toll-free: (877) 307-6855 (US only) Fax: (484) 875-9830 info@obj-sys.com |