/* Copyright 2006 Joachim Zobel <jz-2006@heute-morgen.de>.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

 /*
  * This is mod_xml2. It has nothing to do with mod_xml. The name is as 
  * it is because it is a wrapper to the gnome libxml2 and mod_libxml2
  * is ugly. It is runs the libxml2 SAX2 parser and converts its input 
  * into SAX buckets. These are SAX events wrapped into buckets. They 
  * morph back into heap buckets if you call their bucket read function.
  * This means that nothing needs to be done to convert them back.
  * It also means that you have to be carefull, once you treat them as
  * ordinary buckets (e.g. by using an "ordinary" filter), they are.
  * So if you only run the xml2 filter on XML input you will rarely
  * notice it. Whitespace inside tags is normalized.
  *
  * It also provides functionality for converting portions of the document
  * into document trees and using tree transformation functions on them.
  * See tree_transform.h and mod_i18n.c on how to do this.
  *
  * This module should work as a drop in replacement for mod_expat,
  * which I will not maintain.
  *
  * Filters using SAX buckets currently are mod_i18n and mod_xi.
  * 
  * The module should be able to run on large files, which is actually
  * the point with both SAX and Apache filters. Allocation of per request 
  * memory is done once for every tag name, attribute name and namespace. 
  * So as long as your XML file is not permanently introducing new tags
  * or new namespaces this is limited. Check sax_unify_name to see
  * what exactly happens.
  * 
  * It is compiled and installed as expected with
  * apxs2 -i -c -I /usr/include/libxml2 mod_xml2.c buckets_sax.c 
  *       frag_buffer.c sax_util.c sxpath.c tree_transform.c 
  *       /usr/local/lib/libxml2.la
  *
  * Configuration
  *
  * The name of the filter for generating SAX buckets is sax.
  *
  * Configuration Directives
  *
  * XML2Parse xml|html
  * Context: server config, virtual host, directory, .htaccess
  * This switches from the libxml2 XML parser to the liberal
  * libxml2 HTML parser.
  *
  */
