diff options
author | fmoga <fmoga@13f79535-47bb-0310-9956-ffa450edef68> | 2010-08-15 07:25:44 +0000 |
---|---|---|
committer | fmoga <fmoga@13f79535-47bb-0310-9956-ffa450edef68> | 2010-08-15 07:25:44 +0000 |
commit | ce3c5536c9af5f535d0057498d0d76848b7a4cb5 (patch) | |
tree | 8ed58bca59499a71f87bab57d0327ed195b8ad47 /sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/CometServiceBindingProvider.java | |
parent | d6451b81703c809abcd0f51e74abdba7c732b513 (diff) |
Added Javascript proxy generation.
Added passing parameters through JSON.
Added Gson and jquery-json as dependencies.
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@985622 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to '')
-rw-r--r-- | sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/CometServiceBindingProvider.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/CometServiceBindingProvider.java b/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/CometServiceBindingProvider.java index 5ad23097b5..1d295d9b4d 100644 --- a/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/CometServiceBindingProvider.java +++ b/sca-java-2.x/contrib/modules/binding-comet-runtime/src/main/java/org/apache/tuscany/sca/binding/comet/runtime/CometServiceBindingProvider.java @@ -20,6 +20,7 @@ package org.apache.tuscany.sca.binding.comet.runtime; import org.apache.tuscany.sca.assembly.ComponentService; +import org.apache.tuscany.sca.binding.comet.runtime.javascript.JavascriptGenerator; import org.apache.tuscany.sca.host.http.ServletHost; import org.apache.tuscany.sca.interfacedef.Interface; import org.apache.tuscany.sca.interfacedef.InterfaceContract; @@ -40,7 +41,9 @@ public class CometServiceBindingProvider implements ServiceBindingProvider { public void start() { ComponentService service = endpoint.getService(); Interface serviceInterface = service.getInterfaceContract().getInterface(); + JavascriptGenerator.generateServiceProxy(service); for (Operation operation : serviceInterface.getOperations()) { + JavascriptGenerator.generateMethodProxy(service, operation); ServletFactory.registerServlet(servletHost, endpoint, operation); } } @@ -49,7 +52,7 @@ public class CometServiceBindingProvider implements ServiceBindingProvider { ComponentService service = endpoint.getService(); Interface serviceInterface = service.getInterfaceContract().getInterface(); for (Operation op : serviceInterface.getOperations()) { - String path = endpoint.getBinding().getURI() + "/" + op.getName(); + String path = service.getName() + "/" + op.getName(); servletHost.removeServletMapping(path); } } |