void (final String className, final Element enumPropertyElement) { Map<String, IntEnumEditor.Pair[]> map = new HashMap<>(); for (Element e : enumPropertyElement.getChildren("property")) { final String name = LwXmlReader.getRequiredString(e, Constants.NAME); final List list = e.getChildren("constant"); IntEnumEditor.Pair[] pairs = new IntEnumEditor.Pair[list.size()]; for (int i = 0; i < list.size(); i++) { Element constant = (Element)list.get(i); int value = LwXmlReader.getRequiredInt(constant, Constants.VALUE); String message = constant.getAttributeValue("message"); String text = (message != null) ? UIDesignerBundle.message(message) : LwXmlReader.getRequiredString(constant, Constants.NAME); pairs[i] = new IntEnumEditor.Pair(value, text); } map.put(name, pairs); } if (map.size() > 0) { myClass2EnumProperties.put(className, map); } }