... | @@ -39,7 +39,7 @@ The implementation is called a handler. |
... | @@ -39,7 +39,7 @@ The implementation is called a handler. |
|
DelightConfig cfg = DelightConfigFinder.getDefaultConfig()
|
|
DelightConfig cfg = DelightConfigFinder.getDefaultConfig()
|
|
DelightServer server = new DelightServer(cfg)
|
|
DelightServer server = new DelightServer(cfg)
|
|
.port( 8080 )
|
|
.port( 8080 )
|
|
.contextPath( "/example-delight-webapp/delight" )
|
|
.contextPath( "/my-service" )
|
|
.init( backend -> {
|
|
.init( backend -> {
|
|
backend.addHandlerByClass("handler-x", ServiceImpl.class);
|
|
backend.addHandlerByClass("handler-x", ServiceImpl.class);
|
|
});
|
|
});
|
... | @@ -53,7 +53,7 @@ Now you can do RPC calls to this backend with any tool which is able to send HTT |
... | @@ -53,7 +53,7 @@ Now you can do RPC calls to this backend with any tool which is able to send HTT |
|
Using the service from a Java client is as easy as
|
|
Using the service from a Java client is as easy as
|
|
|
|
|
|
Delight delight = new Delight(DelightConfigFinder.getDefaultConfig());
|
|
Delight delight = new Delight(DelightConfigFinder.getDefaultConfig());
|
|
ServiceApi client = delight.connectingTo("http://localhost:8080/example-delight-webapp/delight")
|
|
ServiceApi client = delight.connectingTo("http://localhost:8080/my-service")
|
|
.usingApi("handler-x", ServiceApi.class);
|
|
.usingApi("handler-x", ServiceApi.class);
|
|
String retVal = client.soDomething( new TestPojo(...) );
|
|
String retVal = client.soDomething( new TestPojo(...) );
|
|
|
|
|
... | @@ -82,7 +82,7 @@ The following capabilities exist: |
... | @@ -82,7 +82,7 @@ The following capabilities exist: |
|
|
|
|
|
* __Arrays of primitive and complex types__ are permitted
|
|
* __Arrays of primitive and complex types__ are permitted
|
|
|
|
|
|
* __null String values__ are represented with the zero byte (ASCII 0 / NUL). Specify it with Url encoding: '?parameterNull=%00'
|
|
* __null String values__ are represented with the zero byte (ASCII 0 / NUL). Specify it with URL encoding: '?parameterNull=%00'
|
|
|
|
|
|
GET http://localhost:8080/my-service/handler-x?parameterNull=%00
|
|
GET http://localhost:8080/my-service/handler-x?parameterNull=%00
|
|
|
|
|
... | | ... | |