setAudioDeviceOnline method

void setAudioDeviceOnline(
  1. String id, {
  2. bool online = true,
  3. String venueId = 'default',
})

Test hook: the media server sees audio device id come online / go offline (audioDevice.state patch).

Implementation

void setAudioDeviceOnline(
  String id, {
  bool online = true,
  String venueId = 'default',
}) {
  final v = _venueId(venueId);
  final d = _audioDevice(v, id);
  (d['state']! as Map<String, Object?>)['online'] = online;
  bus.publish(
    DomeTopics.audioDevice(v, id),
    EventKinds.audioDeviceState,
    patch: {
      'state': {'online': online},
    },
  );
}