void (final StringDescriptor descriptor, final String valueAttr, final String bundleAttr, final String keyAttr) { if(descriptor.getValue() != null){ // direct value addAttribute(valueAttr, descriptor.getValue()); if (descriptor.isNoI18n()) { addAttribute(UIFormXmlConstants.ATTRIBUTE_NOI18N, Boolean.TRUE.toString()); } } else{ // via resource bundle addAttribute(bundleAttr, descriptor.getBundleName()); addAttribute(keyAttr, descriptor.getKey()); } }