Java supports client results (#28147)
parent
d20cc8ecd7
commit
e38284cba9
|
@ -40,7 +40,7 @@ The table below shows the features and support for the clients that offer real-t
|
|||
| Long Polling Transport |2.1.0|1.0.0|1.0.0|3.0.0|
|
||||
| JSON Hub Protocol |2.1.0|1.0.0|1.0.0|1.0.0|
|
||||
| MessagePack Hub Protocol |2.1.0|1.0.0|1.0.0|5.0.0|
|
||||
| Client Results |7.0.0|7.0.0|7.0.0|❌|
|
||||
| Client Results |7.0.0|7.0.0|7.0.0|7.0.0|
|
||||
|
||||
Support for enabling additional client features is tracked in [our issue tracker](https://github.com/dotnet/AspNetCore/issues).
|
||||
|
||||
|
|
|
@ -689,6 +689,14 @@ hubConnection.on("GetMessage", async () => {
|
|||
});
|
||||
```
|
||||
|
||||
#### Java client
|
||||
|
||||
```java
|
||||
hubConnection.onWithResult("GetMessage", () -> {
|
||||
return Single.just("message");
|
||||
});
|
||||
```
|
||||
|
||||
## Change the name of a hub method
|
||||
|
||||
By default, a server hub method name is the name of the .NET method. To change this default behavior for a specific method, use the [HubMethodName](xref:Microsoft.AspNetCore.SignalR.HubMethodNameAttribute) attribute. The client should use this name instead of the .NET method name when invoking the method:
|
||||
|
|
Loading…
Reference in New Issue