private void addLocalizedFieldToCollection(Collection fields, Locale locale, String value)
{
try
{
LocalizedField localizedField = metadata.createLocalizedField();
//TODO: switch to object creation through another mechanism
//(LocalizedField) JetspeedPortletRegistry.getNewObjectInstance(MutableDescription.TYPE_WEB_APP, true);
localizedField.setLocale(locale);
localizedField.setValue(value);
fields.add(localizedField);
}
catch(Exception e)
{
String msg = "Unable to instantiate LocalizedField implementor, " + e.toString();