comparableNamespaces.add(XMLSecEventFactory.createXMLSecNamespace(element.getPrefix(), element.getNamespaceURI()));
}
if (attributes != null) {
for (int i = 0; i < attributes.size(); i++) {
XMLSecAttribute xmlSecAttribute = attributes.get(i);
QName attributeName = xmlSecAttribute.getName();
String attributeNamePrefix = attributeName.getPrefix();
if (attributeNamePrefix != null && attributeNamePrefix.isEmpty()) {
continue;
}
if (!comparableNamespaces.contains(xmlSecAttribute.getAttributeNamespace())) {
if (comparableNamespaces == Collections.<XMLSecNamespace>emptyList()) {
comparableNamespaces = new ArrayList<XMLSecNamespace>(1);
}
comparableNamespaces.add(xmlSecAttribute.getAttributeNamespace());
}
}
}
XMLSecStartElement xmlSecStartElement
= XMLSecEventFactory.createXmlSecStartElement(element, attributes, comparableNamespaces);