diff options
author | antelder <antelder@13f79535-47bb-0310-9956-ffa450edef68> | 2010-01-28 15:30:53 +0000 |
---|---|---|
committer | antelder <antelder@13f79535-47bb-0310-9956-ffa450edef68> | 2010-01-28 15:30:53 +0000 |
commit | 98ee3e408708769ee60ab0d64e042220c6763f0c (patch) | |
tree | 9234147c6ba9b8e5123ff44a20507862c8b7cc54 /sca-java-2.x/trunk/modules/sca-client-javascript/src | |
parent | f434c7a721f38902f439227187c6547641a62d85 (diff) |
Temporarily comment some broken code out till i fix it
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@904129 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'sca-java-2.x/trunk/modules/sca-client-javascript/src')
-rw-r--r-- | sca-java-2.x/trunk/modules/sca-client-javascript/src/main/java/org/apache/tuscany/sca/client/javascript/ScriptEngine.java | 47 |
1 files changed, 25 insertions, 22 deletions
diff --git a/sca-java-2.x/trunk/modules/sca-client-javascript/src/main/java/org/apache/tuscany/sca/client/javascript/ScriptEngine.java b/sca-java-2.x/trunk/modules/sca-client-javascript/src/main/java/org/apache/tuscany/sca/client/javascript/ScriptEngine.java index 56796de699..41fb224cd3 100644 --- a/sca-java-2.x/trunk/modules/sca-client-javascript/src/main/java/org/apache/tuscany/sca/client/javascript/ScriptEngine.java +++ b/sca-java-2.x/trunk/modules/sca-client-javascript/src/main/java/org/apache/tuscany/sca/client/javascript/ScriptEngine.java @@ -177,7 +177,7 @@ public class ScriptEngine extends ScriptableObject implements Runnable{ this.startScriptEngine();
}
finally {
- tuscany.stop();
+// tuscany.stop();
Thread.currentThread().setContextClassLoader(oldClassLoader);
Context.exit();
}
@@ -288,30 +288,33 @@ public class ScriptEngine extends ScriptableObject implements Runnable{ * This method is defined as a script function.
*/
public void listServices() {
- EndpointRegistry epr = tuscany.getEndpointRegistry();
- for (Endpoint e : epr.getEndpoints()) {
- out.println(e.getURI());
- }
+ // FIXME
+// EndpointRegistry epr = tuscany.getEndpointRegistry();
+// for (Endpoint e : epr.getEndpoints()) {
+// out.println(e.getURI());
+// }
}
public Object getService(String serviceName) {
- ExtensionPointRegistry extensionsRegistry = tuscany.getExtensionsRegistry();
- FactoryExtensionPoint factories = extensionsRegistry.getExtensionPoint(FactoryExtensionPoint.class);
- AssemblyFactory assemblyFactory = factories.getFactory(AssemblyFactory.class);
-
- EndpointReference endpointReference = assemblyFactory.createEndpointReference();
- endpointReference.setReference(assemblyFactory.createComponentReference());
- Endpoint targetEndpoint = assemblyFactory.createEndpoint();
- targetEndpoint.setURI(serviceName);
- endpointReference.setTargetEndpoint(targetEndpoint);
- EndpointRegistry epr = tuscany.getEndpointRegistry();
- List<Endpoint> er = epr.findEndpoint(endpointReference);
- if (er.size() < 1) {
- err.println("service not found " + serviceName);
- return null;
- }
- JavaInterface ifac = (JavaInterface)er.get(0).getComponentServiceInterfaceContract().getInterface();
- return getService(serviceName, ifac.getName());
+ // FIXME
+// ExtensionPointRegistry extensionsRegistry = tuscany.getExtensionsRegistry();
+// FactoryExtensionPoint factories = extensionsRegistry.getExtensionPoint(FactoryExtensionPoint.class);
+// AssemblyFactory assemblyFactory = factories.getFactory(AssemblyFactory.class);
+//
+// EndpointReference endpointReference = assemblyFactory.createEndpointReference();
+// endpointReference.setReference(assemblyFactory.createComponentReference());
+// Endpoint targetEndpoint = assemblyFactory.createEndpoint();
+// targetEndpoint.setURI(serviceName);
+// endpointReference.setTargetEndpoint(targetEndpoint);
+// EndpointRegistry epr = tuscany.getEndpointRegistry();
+// List<Endpoint> er = epr.findEndpoint(endpointReference);
+// if (er.size() < 1) {
+// err.println("service not found " + serviceName);
+// return null;
+// }
+// JavaInterface ifac = (JavaInterface)er.get(0).getComponentServiceInterfaceContract().getInterface();
+// return getService(serviceName, ifac.getName());
+ return null;
}
/**
|