summaryrefslogtreecommitdiffstats
path: root/branches
diff options
context:
space:
mode:
authorlresende <lresende@13f79535-47bb-0310-9956-ffa450edef68>2008-12-18 00:25:30 +0000
committerlresende <lresende@13f79535-47bb-0310-9956-ffa450edef68>2008-12-18 00:25:30 +0000
commiteef22294a6c5036a9d1fb7145703dacc2f4c42e0 (patch)
treebb61c7b30aa9e6cc40367a5c1c3f952230e924aa /branches
parent432dd8fb555ad9d6dde1b5d220e7a0fe2de51904 (diff)
Sample changes needed to bootstrap Tuscany extensions in Android, as the extension mechanism based on meta-inf files does not work in android
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@727601 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r--branches/sca-java-1.x/modules/host-android/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java11
1 files changed, 8 insertions, 3 deletions
diff --git a/branches/sca-java-1.x/modules/host-android/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java b/branches/sca-java-1.x/modules/host-android/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java
index 55b6afb6f2..14e1556896 100644
--- a/branches/sca-java-1.x/modules/host-android/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java
+++ b/branches/sca-java-1.x/modules/host-android/src/main/java/org/apache/tuscany/sca/host/embedded/impl/ReallySmallRuntime.java
@@ -37,6 +37,7 @@ import org.apache.tuscany.sca.assembly.SCABindingFactory;
import org.apache.tuscany.sca.assembly.builder.CompositeBuilder;
import org.apache.tuscany.sca.assembly.builder.CompositeBuilderException;
import org.apache.tuscany.sca.contribution.ContributionFactory;
+import org.apache.tuscany.sca.contribution.DefaultModelFactoryExtensionPoint;
import org.apache.tuscany.sca.contribution.ModelFactoryExtensionPoint;
import org.apache.tuscany.sca.contribution.processor.URLArtifactProcessor;
import org.apache.tuscany.sca.contribution.processor.URLArtifactProcessorExtensionPoint;
@@ -44,6 +45,7 @@ import org.apache.tuscany.sca.contribution.resolver.DefaultModelResolver;
import org.apache.tuscany.sca.contribution.resolver.ModelResolver;
import org.apache.tuscany.sca.contribution.service.ContributionService;
import org.apache.tuscany.sca.core.DefaultExtensionPointRegistry;
+import org.apache.tuscany.sca.core.DefaultUtilityExtensionPoint;
import org.apache.tuscany.sca.core.ExtensionPointRegistry;
import org.apache.tuscany.sca.core.ModuleActivator;
import org.apache.tuscany.sca.core.UtilityExtensionPoint;
@@ -89,7 +91,7 @@ public class ReallySmallRuntime {
private ContributionService contributionService;
private CompositeActivator compositeActivator;
private CompositeBuilder compositeBuilder;
- // private DomainBuilder domainBuilder;
+
private WorkScheduler workScheduler;
private ScopeRegistry scopeRegistry;
private ProxyFactory proxyFactory;
@@ -106,7 +108,9 @@ public class ReallySmallRuntime {
// Create our extension point registry
registry = new DefaultExtensionPointRegistry();
- UtilityExtensionPoint utilities = registry.getExtensionPoint(UtilityExtensionPoint.class);
+
+ UtilityExtensionPoint utilities = new DefaultUtilityExtensionPoint(registry);
+ registry.addExtensionPoint(utilities);
// Get work scheduler
workScheduler = utilities.getUtility(WorkScheduler.class);
@@ -115,7 +119,8 @@ public class ReallySmallRuntime {
InterfaceContractMapper mapper = utilities.getUtility(InterfaceContractMapper.class);
// Get factory extension point
- ModelFactoryExtensionPoint factories = registry.getExtensionPoint(ModelFactoryExtensionPoint.class);
+ ModelFactoryExtensionPoint factories = new DefaultModelFactoryExtensionPoint();
+ registry.addExtensionPoint(factories);
// Get Message factory
MessageFactory messageFactory = factories.getFactory(MessageFactory.class);