docs: @SuppressWarnings({"checkstyle:cyclomaticcomplexity", "checkstyle:nestedifdepth"})
  	public static void readAttributeContainer(Element element, AttributeCollection container,
  			PathBuilder pathBuilder, XMLResources resources, boolean readStandardAttribute) throws IOException {
  		for (final Element attrNode : XMLUtil.getElementsFromPath(element, NODE_ATTRIBUTES, NODE_ATTRIBUTE)) {
  			final String name = XMLUtil.getAttributeValue(attrNode, XMLUtil.ATTR_NAME);
  			if (name != null && (readStandardAttribute
  					|| (!"".equals(name) //$NON-NLS-1$
  							&& !XMLUtil.ATTR_ID.equalsIgnoreCase(name)
  							&& !XMLUtil.ATTR_NAME.equalsIgnoreCase(name)
  							&& !XMLUtil.ATTR_COLOR.equalsIgnoreCase(name)
  							&& !ATTR_GEOID.equalsIgnoreCase(name)))) {
  				final String type = XMLUtil.getAttributeValue(attrNode, ATTR_TYPE);
  				if (type != null && !"".equals(type)) { //$NON-NLS-1$
  					AttributeType attrType;
  					try {
  						attrType = AttributeType.valueOf(type);
  					} catch (Throwable exception) {
  						attrType = null;
  					}
  					if (attrType != null) {
  						final String value;
  						switch (attrType) {
  						case DATE:
  							value = XMLUtil.getAttributeValue(attrNode, ATTR_VALUE);
  							if (value != null && !"".equals(value)) { //$NON-NLS-1$
  								try {
  									final Date d = XMLUtil.parseDate(value);
  									final AttributeImpl attr = new AttributeImpl(name, d);
  									container.setAttribute(attr);
  								} catch (DateFormatException e) {
  									throw new IOException(e);
  								} catch (AttributeException e) {
  									throw new IOException(e);
  								}
  							}
  							break;
  						case URL:
  							value = XMLUtil.getAttributeValue(attrNode, ATTR_VALUE);
  							if (value != null && !"".equals(value)) { //$NON-NLS-1$
  								try {
  									final long id = XMLResources.getNumericalIdentifier(value);
  									final URL url = resources.getResourceURL(id);
  									if (url != null) {
  										final AttributeImpl attr = new AttributeImpl(name, url);
  										container.setAttribute(attr);
  									}
  								} catch (IllegalArgumentException e) {
  									throw new IOException(e);
  								} catch (AttributeException e) {
  									throw new IOException(e);
  								}
  							}
  							break;
  							//$CASES-OMITTED$
  						default:
  							value = XMLUtil.getAttributeValue(attrNode, ATTR_VALUE);
  							if (value != null && !"".equals(value)) { //$NON-NLS-1$
  								final AttributeImpl attr = new AttributeImpl(name, value);
  								attr.cast(attrType);
  								try {
  									container.setAttribute(attr);
  								} catch (AttributeException e) {
  									throw new IOException(e);
  								}
  							}
  							break;
  						}
  					}
  				}
  			}
  		}
  	}