File tree 3 files changed +7
-12
lines changed
src/main/java/com/googlecode/jsonrpc4j/spring
3 files changed +7
-12
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ JSON-RPC).
16
16
* HTTP Server (` HttpServletRequest ` \ ` HttpServletResponse ` )
17
17
* Portlet Server (` ResourceRequest ` \ ` ResourceResponse ` )
18
18
* Socket Server (` StreamServer ` )
19
- * Integration with the Spring Framework ( ` RemoteExporter ` )
19
+ * Integration with the Spring Framework
20
20
* Streaming client
21
21
* HTTP client
22
22
* Dynamic client proxies
@@ -66,7 +66,7 @@ that take `InputStream`s and `OutputStream`s. Also in the library is a `JsonRpc
66
66
which extends the ` JsonRpcClient ` to add HTTP support.
67
67
68
68
## Spring Framework
69
- jsonrpc4j provides a ` RemoteExporter ` to expose java services as JSON-RPC over HTTP without
69
+ jsonrpc4j provides support for exposing java services as JSON-RPC over HTTP without
70
70
requiring any additional work on the part of the programmer. The following example explains
71
71
how to use the ` JsonServiceExporter ` within the Spring Framework.
72
72
@@ -113,7 +113,9 @@ public class UserServiceImpl
113
113
}
114
114
```
115
115
116
- Configure your service in spring as you would any other RemoteExporter:
116
+ Configure your service in Spring as you would do it for any other Beans,
117
+ and then add a reference of your service Bean into ` JsonServiceExporter `
118
+ by specifying the ` service ` and ` serviceInterface ` properties:
117
119
118
120
``` xml
119
121
<?xml version =" 1.0" encoding =" UTF-8" ?>
Original file line number Diff line number Diff line change 9
9
import java .io .IOException ;
10
10
11
11
/**
12
- * {@link HttpRequestHandler} that exports services using Json
13
- * according to the JSON-RPC proposal specified at:
14
- * <a href="http://groups.google.com/group/json-rpc">
15
- * http://groups.google.com/group/json-rpc</a>.
12
+ * {@link HttpRequestHandler} that exports user services using JSON-RPC over HTTP protocol
16
13
*/
17
14
public class JsonServiceExporter extends AbstractJsonServiceExporter implements HttpRequestHandler {
18
15
Original file line number Diff line number Diff line change 11
11
12
12
13
13
/**
14
- * {@link org.springframework.remoting.support.RemoteExporter RemoteExporter}
15
- * that exports services using Json according to the JSON-RPC proposal specified
16
- * at:
17
- * <a href="http://groups.google.com/group/json-rpc">
18
- * http://groups.google.com/group/json-rpc</a>.
14
+ * Exports user defined services as streaming server, which provides JSON-RPC over sockets.
19
15
*/
20
16
@ SuppressWarnings ("unused" )
21
17
public class JsonStreamServiceExporter extends AbstractJsonServiceExporter implements DisposableBean {
You can’t perform that action at this time.
0 commit comments