public Map < Artifact , Dependency > resolve ( BomConfig config ) throws Exception { Map < Artifact , Dependency > dependencies = new LinkedHashMap < Artifact , Dependency > ( ) ; if ( config != null && config . getImports ( ) != null ) { for ( BomImport bom : config . getImports ( ) ) { Map < Artifact , Dependency > deps = resolve ( bom ) ; for ( Map . Entry < Artifact , Dependency > e : deps . entrySet ( ) ) { if ( ! dependencies . containsKey ( e . getKey ( ) ) ) { // order is important for imported boms dependencies . put ( e . getKey ( ) , e . getValue ( ) ) ; } } } } return dependencies ; }
Resolve all imports contained in the given configuration .