}
// copy unique new metadata members
Iterator fieldIter = fields.iterator();
while (fieldIter.hasNext())
{
LocalizedField field = (LocalizedField)fieldIter.next();
if (!this.fields.contains(field))
{
addField(field.getLocale(), field.getName(), field.getValue());
}
}
}
// update field map
MultiValueMap fieldMap = getFieldMap(false);
if (fieldMap != null)
{
fieldMap.clear();
}
if (this.fields != null)
{
Iterator fieldIter = this.fields.iterator();
while (fieldIter.hasNext())
{
LocalizedField field = (LocalizedField)fieldIter.next();
getFieldMap(true).put(field.getName(), field);
}
}
}