mirror of
https://github.com/AlexMacocian/Net.Sdk.Web.Extensions.git
synced 2026-07-15 13:39:29 +00:00
Showcase support for IActionFilter and IAsyncActionFilter
This commit is contained in:
@@ -57,6 +57,14 @@ public class CustomRoute : WebSocketRouteBase<CustomRequest, CustomResponse>
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Support for `IActionFilter`
|
||||||
|
Decorate your `CustomRoute` with filters that get executed the same way as in a AspNetCore web app
|
||||||
|
Both `IActionFilter` and `IAsyncActionFilter` are supported
|
||||||
|
```C#
|
||||||
|
[ServiceFilter<CustomFilter>]
|
||||||
|
public class CustomRoute : WebSocketRouteBase<CustomRequest, CustomResponse>
|
||||||
|
```
|
||||||
|
|
||||||
### Custom message converters
|
### Custom message converters
|
||||||
If you need specialized converters, implement your own `WebSocketMessageConverter<T>`
|
If you need specialized converters, implement your own `WebSocketMessageConverter<T>`
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user