question: @ SuppressWarnings ( "unchecked" ) private void addVertex ( Configuration configuration , String configName , Consumer < String > nameValidator ) { if ( ! configuration . containsKey ( MODULE_NAME_KEY ) ) { LOG . warn ( MODULE_NAME_MISSING . logFormat ( configName ) ) ; return ; } String moduleName = configuration . getString ( MODULE_NAME_KEY ) ; nameValidator . accept ( moduleName ) ; LOG . debug ( MODULE_FOUND_MESSAGE . logFormat ( moduleName , configName ) ) ; if ( moduleConfigurations . containsKey ( moduleName ) ) { LOG . error ( MODULE_NAME_DUPLICATION . format ( configName , moduleName ) ) ; throw new SystemConfigException ( MODULE_NAME_DUPLICATION . format ( configName , moduleName ) ) ; } moduleConfigurations . put ( moduleName , configuration ) ; List < String > dependencies = new ArrayList < > ( configuration . getList ( DEPENDENT_MODULE_KEY , Collections . < String > emptyList ( ) ) ) ; Collections . reverse ( dependencies ) ; moduleDependencies . put ( moduleName , dependencies ) ; }
target:  Take a configuration and if it is a valid module, load it into the moduleConfigurations map and load it's dependency moduleDependencies.