Package energy.eddie.aiida.web
Class EventStream
java.lang.Object
energy.eddie.aiida.web.EventStream
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T> org.springframework.http.ResponseEntity<reactor.core.publisher.Flux<T>> toJson(reactor.core.publisher.Flux<T> stream) Wraps a flux for an SSE endpointproduces = TEXT_EVENT_STREAM_VALUE.
-
Constructor Details
-
EventStream
public EventStream()
-
-
Method Details
-
toJson
public <T> org.springframework.http.ResponseEntity<reactor.core.publisher.Flux<T>> toJson(reactor.core.publisher.Flux<T> stream) Wraps a flux for an SSE endpointproduces = TEXT_EVENT_STREAM_VALUE.- Type Parameters:
T- the type of the source of the events- Parameters:
stream- the source for the events- Returns:
- the SSE response
-