Class NamespaceExtractor


  • public class NamespaceExtractor
    extends Object
    Extracts namespace mapping information from an XML file. XML file is parsed and all startPrefixMapping events are intercepted. Scoping of prefix mapping within the XML file may result in multiple namespace using the same prefix. This is handled by mangling the prefix when required. The resulting NamespaceMapping implements NamespaceResolver and can be used by tools (such as o.a.j.tools.nodetype.CompactNodeTypeDefWriter) to resolve namespaces.