onRhythmPlayerStateChanged property

void Function(RhythmPlayerStateType state, RhythmPlayerReason reason)? onRhythmPlayerStateChanged
final

Callback when the state of the virtual metronome changes.

Deprecated Deprecated since v6.6.2. When the state of the virtual metronome changes, the SDK triggers this callback to report the current state. If a fault occurs with the virtual metronome, this callback helps you understand the current state and the reason for the fault, allowing you to troubleshoot. This callback applies to Android and iOS only.

  • state The current state of the virtual metronome. See RhythmPlayerStateType.
  • reason The error code and message when the virtual metronome encounters an error. See RhythmPlayerReason.

Implementation

final void Function(RhythmPlayerStateType state, RhythmPlayerReason reason)?
    onRhythmPlayerStateChanged;