You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by Adam Horvath <Ad...@birdstep.com> on 2008/04/28 17:24:19 UTC

Reducing Lib Size ?

Hello,
we are considering using Xerces, but the 1.9 MB Win32 Release build is a
bit to big. We will not use SAX nor Schemas, is there a straightforward
way to eliminate those from the library build. My first impression is
that it is not, but I hope that I am wrong.
 
Kindly
Adam Horvath

Re: Reducing Lib Size ?

Posted by Boris Kolpackov <bo...@codesynthesis.com>.
Hi Jesse,

Jesse Pelton <js...@PKC.com> writes:

> I don't know whether there's a good way to carve off sections of the
> library, but I'm pretty sure the DOM parser is built on SAX, so removing
> SAX would be an option only if you don't need to parse.

To be more precise, both SAX and DOM parsers are built on top of a
low-level, SAX-like parser. As a result, SAX implementation is quite
thin so removing it won't give you much. XML Schema support, on the
other hand, can result in a more significant gain though it could
also be significantly more complicated to remove.

While there are implementations of XML scanners (that's where XML
Schema and DTD validation happens) that don't depend on XML Schema
support (e.g., DGXMLScanner and WFXMLScanner), there is also such
a thing as DOM type information which allows you to query XML Schema
grammar corresponding to the parsed DOM nodes.

Overall, I think it shouldn't be too difficult to get rid of XML Schema
support if you don't mind making some source code changes.

Boris

-- 
Boris Kolpackov, Code Synthesis Tools   http://codesynthesis.com/~boris/blog
Open source XML data binding for C++:   http://codesynthesis.com/products/xsd
Mobile/embedded validating XML parsing: http://codesynthesis.com/products/xsde

---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: c-dev-help@xerces.apache.org


RE: Reducing Lib Size ?

Posted by Jesse Pelton <js...@PKC.com>.
I don't know whether there's a good way to carve off sections of the
library, but I'm pretty sure the DOM parser is built on SAX, so removing
SAX would be an option only if you don't need to parse.

________________________________

From: Adam Horvath [mailto:Adam.Horvath@birdstep.com] 
Sent: Monday, April 28, 2008 11:24 AM
To: c-dev@xerces.apache.org
Subject: Reducing Lib Size ?


Hello,
we are considering using Xerces, but the 1.9 MB Win32 Release build is a
bit to big. We will not use SAX nor Schemas, is there a straightforward
way to eliminate those from the library build. My first impression is
that it is not, but I hope that I am wrong.
 
Kindly
Adam Horvath