onPerformanceAlarms property
@detail callback
@author panjian.fishing
@brief When the publish performance fallback setPublishFallbackOption{@link #RTCEngine#setPublishFallbackOption} is not turned on locally, and when insufficient device performance is detected, this callback is received.
When the setPublishFallbackOption{@link #RTCEngine#setPublishFallbackOption} is locally turned on, ans when the publish performance fallback/recovery is caused due to device performance/network reasons, this callback is received.
@param streamId Stream ID
@param streamInfo Stream information, see StreamInfo{@link #StreamInfo}.
@param mode Indicates whether the release fallback function is turned on locally. See PerformanceAlarmMode{@link #PerformanceAlarmMode}
- When the publisher does not turn on the release performance fallback, the mode value is NORMAL.
- When the publisher turns on the release performance fallback, the mode value is SIMULCAST.
@param reason For alarm reasons. See PerformanceAlarmReason{@link #PerformanceAlarmReason}
@param data Performance fallback related data. See SourceWantedData{@link #SourceWantedData}.
Implementation
FutureOr<void> Function(
String streamId,
StreamInfo streamInfo,
PerformanceAlarmMode mode,
PerformanceAlarmReason reason,
SourceWantedData data)? onPerformanceAlarms;