modules/host-android/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java [265:304]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    private void  loadSCADefinitions() throws ActivationException {
        try {
            URLArtifactProcessorExtensionPoint documentProcessors = registry.getExtensionPoint(URLArtifactProcessorExtensionPoint.class);
            URLArtifactProcessor<SCADefinitions> definitionsProcessor = documentProcessors.getProcessor(SCADefinitions.class);
            SCADefinitionsProviderExtensionPoint scaDefnProviders = registry.getExtensionPoint(SCADefinitionsProviderExtensionPoint.class);
            
            SCADefinitions systemSCADefinitions = new SCADefinitionsImpl();
            SCADefinitions aSCADefn = null;
            for ( SCADefinitionsProvider aProvider : scaDefnProviders.getSCADefinitionsProviders() ) {
               aSCADefn = aProvider.getSCADefinition(); 
               SCADefinitionsUtil.aggregateSCADefinitions(aSCADefn, systemSCADefinitions);
            }
            
            policyDefinitions.add(systemSCADefinitions);
            
            //we cannot expect that providers will add the intents and policysets into the resolver
            //so we do this here explicitly
            for ( Intent intent : systemSCADefinitions.getPolicyIntents() ) {
                policyDefinitionsResolver.addModel(intent);
            }
            
            for ( PolicySet policySet : systemSCADefinitions.getPolicySets() ) {
                policyDefinitionsResolver.addModel(policySet);
            }
            
            for ( IntentAttachPointType attachPoinType : systemSCADefinitions.getBindingTypes() ) {
                policyDefinitionsResolver.addModel(attachPoinType);
            }
            
            for ( IntentAttachPointType attachPoinType : systemSCADefinitions.getImplementationTypes() ) {
                policyDefinitionsResolver.addModel(attachPoinType);
            }
            
            //now that all system sca definitions have been read, lets resolve them right away
            definitionsProcessor.resolve(systemSCADefinitions, 
                                         policyDefinitionsResolver);
        } catch ( Exception e ) {
            throw new ActivationException(e);
        }
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



modules/host-embedded/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java [262:301]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    private void  loadSCADefinitions() throws ActivationException {
        try {
            URLArtifactProcessorExtensionPoint documentProcessors = registry.getExtensionPoint(URLArtifactProcessorExtensionPoint.class);
            URLArtifactProcessor<SCADefinitions> definitionsProcessor = documentProcessors.getProcessor(SCADefinitions.class);
            SCADefinitionsProviderExtensionPoint scaDefnProviders = registry.getExtensionPoint(SCADefinitionsProviderExtensionPoint.class);
            
            SCADefinitions systemSCADefinitions = new SCADefinitionsImpl();
            SCADefinitions aSCADefn = null;
            for ( SCADefinitionsProvider aProvider : scaDefnProviders.getSCADefinitionsProviders() ) {
               aSCADefn = aProvider.getSCADefinition(); 
               SCADefinitionsUtil.aggregateSCADefinitions(aSCADefn, systemSCADefinitions);
            }
            
            policyDefinitions.add(systemSCADefinitions);
            
            //we cannot expect that providers will add the intents and policysets into the resolver
            //so we do this here explicitly
            for ( Intent intent : systemSCADefinitions.getPolicyIntents() ) {
                policyDefinitionsResolver.addModel(intent);
            }
            
            for ( PolicySet policySet : systemSCADefinitions.getPolicySets() ) {
                policyDefinitionsResolver.addModel(policySet);
            }
            
            for ( IntentAttachPointType attachPoinType : systemSCADefinitions.getBindingTypes() ) {
                policyDefinitionsResolver.addModel(attachPoinType);
            }
            
            for ( IntentAttachPointType attachPoinType : systemSCADefinitions.getImplementationTypes() ) {
                policyDefinitionsResolver.addModel(attachPoinType);
            }
            
            //now that all system sca definitions have been read, lets resolve them right away
            definitionsProcessor.resolve(systemSCADefinitions, 
                                         policyDefinitionsResolver);
        } catch ( Exception e ) {
            throw new ActivationException(e);
        }
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



