StreamLinkConnection
A coroutine- and Flow-friendly wrapper around a Caplin StreamLink connection.
Extends the raw StreamLink API with suspending helpers for awaiting connection and service state, and with getSubject/getChannel overloads that expose subscriptions and channels as cold Flows of Events. Instances are created via StreamLinkConnectionFactory.connect.
Implements AutoCloseable; closing disconnects the underlying StreamLink.
Properties
A hot SharedFlow of connection status changes, replaying the latest event to collectors.
Functions
Suspends until the connection reaches the ConnectionState.LOGGEDIN state.
Suspends until the service named name reports ServiceStatus.OK, polling periodically.
Subscribes to the container at subject, emitting a ContainerChangeEvent for each row add, remove or clear as its membership changes.
Subscribes to the record at subject, emitting a RecordEvent for each field update.
Subscribes to subject, deserialising each JSON update to T. Reified convenience for getSubject taking an explicit KClass.