public Attributes mapAttributes(final Attributes atts) {
            AttributesImpl natts = new AttributesImpl();
            for (int i = 0; i < atts.getLength(); i++) {
                QName name = attributesMapping.get(new QName(atts.getURI(i), atts.getLocalName(i)));
                if (name != null) {
                    natts.addAttribute(name.getNamespaceURI(), name.getLocalPart(),
                            getQNameAsString(name), atts.getType(i), atts.getValue(i));
                }
            }
            return natts;
        }
A shortcut that automatically creates the QName object
tika-core/src/main/java/org/apache/tika/sax/ElementMappingContentHandler.java