summaryrefslogtreecommitdiffstats
path: root/java/sca/modules/assembly
diff options
context:
space:
mode:
authorrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2009-05-20 16:46:55 +0000
committerrfeng <rfeng@13f79535-47bb-0310-9956-ffa450edef68>2009-05-20 16:46:55 +0000
commitb099739d69690535623b126b37f47bfdfecf040f (patch)
tree252ab5e26d6e6f2c804c43744ff22d68ce3b353f /java/sca/modules/assembly
parentf1863df3c7da7a4632ef3ca70d430d62ed387bad (diff)
Refactoring a few methods on the ServiceDiscover
Adding an OSGi service registry based ExtensionPointRegistry implementation git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@776759 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/sca/modules/assembly')
-rw-r--r--java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/DefaultCompositeBuilderExtensionPoint.java20
1 files changed, 10 insertions, 10 deletions
diff --git a/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/DefaultCompositeBuilderExtensionPoint.java b/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/DefaultCompositeBuilderExtensionPoint.java
index d9b9763475..80b95189ec 100644
--- a/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/DefaultCompositeBuilderExtensionPoint.java
+++ b/java/sca/modules/assembly/src/main/java/org/apache/tuscany/sca/assembly/builder/DefaultCompositeBuilderExtensionPoint.java
@@ -6,23 +6,23 @@
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
- * under the License.
+ * under the License.
*/
package org.apache.tuscany.sca.assembly.builder;
import java.lang.reflect.Constructor;
+import java.util.Collection;
import java.util.HashMap;
import java.util.Map;
-import java.util.Set;
import org.apache.tuscany.sca.assembly.Composite;
import org.apache.tuscany.sca.core.ExtensionPointRegistry;
@@ -68,14 +68,14 @@ public class DefaultCompositeBuilderExtensionPoint implements CompositeBuilderEx
private synchronized void loadBuilders() {
if (loaded)
return;
-
+
FactoryExtensionPoint factories = registry.getExtensionPoint(FactoryExtensionPoint.class);
-
+
UtilityExtensionPoint utils = registry.getExtensionPoint(UtilityExtensionPoint.class);
InterfaceContractMapper mapper = utils.getUtility(InterfaceContractMapper.class);
-
+
// Get the provider factory service declarations
- Set<ServiceDeclaration> builderDeclarations;
+ Collection<ServiceDeclaration> builderDeclarations;
ServiceDiscovery serviceDiscovery = ServiceDiscovery.getInstance();
try {
builderDeclarations = serviceDiscovery.getServiceDeclarations(CompositeBuilder.class.getName());
@@ -113,11 +113,11 @@ public class DefaultCompositeBuilderExtensionPoint implements CompositeBuilderEx
this.factories = factories;
this.mapper = mapper;
}
-
+
public String getID() {
return id;
}
-
+
public void build(Composite composite, Definitions definitions, Monitor monitor) throws CompositeBuilderException {
getBuilder().build(composite, definitions, monitor);
}