private void createPersistenceMaps ( ComponentNameSpaceConfiguration masterCompNSConfig , List < ComponentNameSpaceConfiguration > compNSConfigs ) { Map < Class < ? > , Collection < String > > classesToComponents = new HashMap < Class < ? > , Collection < String > > ( ) ; Map < String , Collection < String > > persistenceRefsToComponents = new HashMap < String , Collection < String > > ( ) ; for ( ComponentNameSpaceConfiguration compNSConfig : compNSConfigs ) { ComponentMetaData cmd = compNSConfig . getComponentMetaData ( ) ; if ( cmd != null ) { String name = cmd . getJ2EEName ( ) . getComponent ( ) ; if ( ! compNSConfig . isMetaDataComplete ( ) ) { List < Class < ? > > classesToScan = compNSConfig . getInjectionClasses ( ) ; if ( classesToScan != null ) { for ( Class < ? > klass : classesToScan ) { for ( Class < ? > superClass = klass ; superClass != null && superClass != Object . class ; superClass = superClass . getSuperclass ( ) ) { addComponentToPersistenceMap ( classesToComponents , superClass , name ) ; } } } } List < ? extends PersistenceContextRef > pcRefs = compNSConfig . getPersistenceContextRefs ( ) ; if ( pcRefs != null ) { for ( PersistenceContextRef ref : pcRefs ) { addComponentToPersistenceMap ( persistenceRefsToComponents , ref . getName ( ) , name ) ; } } List < ? extends PersistenceUnitRef > puRefs = compNSConfig . getPersistenceUnitRefs ( ) ; if ( puRefs != null ) { for ( PersistenceUnitRef ref : puRefs ) { addComponentToPersistenceMap ( persistenceRefsToComponents , ref . getName ( ) , name ) ; } } } } masterCompNSConfig . setPersistenceMaps ( classesToComponents , persistenceRefsToComponents ) ; }
F743 - 30682