public void populatePropertyFromMetaValue(PropertyMap propMap, MetaValue metaValue, PropertyDefinitionMap propDefMap)
{
if (metaValue == null)
return;
PropertiesMetaValue propertiesValue = (PropertiesMetaValue)metaValue;
Set<String> mapMemberPropNames = new HashSet();
for (Object key : propertiesValue.keySet())
mapMemberPropNames.add((String)key);
// There won't be any keys when loading a Configuration for the first time.
for (String mapMemberPropName : mapMemberPropNames)
{
// We assume the PropertyMap is an "open map", since that's what PropertiesMetaValue maps to.
PropertySimple mapMemberProp = propMap.getSimple(mapMemberPropName);
// Create a PropertySimple and populate it.
if (mapMemberProp == null)
{
mapMemberProp = new PropertySimple(mapMemberPropName, propertiesValue.getProperty(mapMemberPropName));
propMap.put(mapMemberProp);
}
}
}