public static void buildMapTypes(EventTypeRepositoryImpl repo,
Map<String, ConfigurationCommonEventTypeMap> mapTypeConfigurations,
Map<String, Properties> mapTypes,
Map<String, Map<String, Object>> nestableMapEvents,
BeanEventTypeFactory beanEventTypeFactory,
ClasspathImportService classpathImportService) {
List<String> creationOrder = EventTypeRepositoryUtil.getCreationOrder(mapTypes.keySet(), nestableMapEvents.keySet(), mapTypeConfigurations);
for (String mapName : creationOrder) {
if (repo.getTypeByName(mapName) != null) {
continue;
}
ConfigurationCommonEventTypeMap mapConfig = mapTypeConfigurations.get(mapName);
Properties propertiesUnnested = mapTypes.get(mapName);
if (propertiesUnnested != null) {
Map<String, Object> propertyTypes = createPropertyTypes(propertiesUnnested, classpathImportService);
LinkedHashMap<String, Object> propertyTypesCompiled = EventTypeUtility.compileMapTypeProperties(propertyTypes, repo);
addNestableMapType(mapName, propertyTypesCompiled, mapConfig, repo, beanEventTypeFactory, repo);
}
Map<String, Object> propertiesNestable = nestableMapEvents.get(mapName);
if (propertiesNestable != null) {
LinkedHashMap<String, Object> propertiesNestableCompiled = EventTypeUtility.compileMapTypeProperties(propertiesNestable, repo);
addNestableMapType(mapName, propertiesNestableCompiled, mapConfig, repo, beanEventTypeFactory, repo);
}
}
}