Companion

Functions

Link copied to clipboard
inline fun <T, R : Any> StreamLinkConnection.getChannel(subject: Subject, send: Flow<T>): Flow<Event<R>>

Opens a bidirectional channel on subject, sending items from send and receiving updates deserialised to R. Reified convenience for getChannel taking an explicit KClass.

Link copied to clipboard
inline fun <T : Any> StreamLinkConnection.getSubject(subject: Subject): Flow<Event<T>>

Subscribes to subject, deserialising each JSON update to T. Reified convenience for getSubject taking an explicit KClass.