ZeroXML is a cross-platform and lightweight XML file abstraction layer that gets it's name from the fact that it can read XML files without allocating any memory for internal use and, when used properly, can handle names and attributes without the need to copy. The library supports both little-endian and big-endian systems and is known to work on Windows, Linux. Full documentation is included in the package.
To achieve zero memory allocation operation the library maps the file to a memory region and walks the XML tree every time a new node is accessed. XML processing might be a bit slower this way but application memory will not get fragmented.
To achieve zero copy the library implements string compare functions for node names, node values, attribute names and attribute values which does Unicode comparison on the memory-mapped data.
Memory will only be allocated to handle client application requests. In all cases a preallocated buffer can be provided by the client application to store XML data for further processing.
Names and values can be converted to the local code-page when the calling application request copying to a new buffer.
A subset of the Xpath path expression syntax can be used to access a specific node or number of nodes within the document.
A caching option is available which will create a node tree when an XML file gets opened. As a result node searches will be much faster at the cost of a small amount of memory (48 bytes on a 64-bit machine for every XML node in the file).