void ( final @NotNull Element itemElement, final @NotNull HashMap<String, StringDescriptor> name2value ) { LOG.assertTrue(ELEMENT_ITEM.equals(itemElement.getName())); if (name2value.size() == 0) { // do not append 'initial-values' subtag return; } final Element initialValuesElement = new Element(ELEMENT_INITIAL_VALUES); itemElement.addContent(initialValuesElement); for (final Map.Entry<String, StringDescriptor> entry : name2value.entrySet()) { final Element propertyElement = new Element(ELEMENT_PROPERTY); initialValuesElement.addContent(propertyElement); propertyElement.setAttribute(ATTRIBUTE_NAME, entry.getKey()); propertyElement.setAttribute(ATTRIBUTE_VALUE, entry.getValue().getValue()/*descriptor is always trivial*/); } }