AiuiEventListener constructor

AiuiEventListener({
  1. void onResult(
    1. AiuiEvent event
    )?,
  2. void onIatResult(
    1. IatResult result,
    2. int responseTime
    )?,
  3. void onNlpResult(
    1. NlpResult result,
    2. int responseTime
    )?,
  4. void onTppResult(
    1. AiuiEvent event
    )?,
  5. void onTtsResult(
    1. TtsResult result
    )?,
  6. void onITransResult(
    1. ITransResult result
    )?,
  7. void onError(
    1. int errorCode,
    2. String message
    )?,
  8. void onStateChange(
    1. int stateCode
    )?,
  9. void onWakeup(
    1. WakeupType type,
    2. String? message
    )?,
  10. void onSleep(
    1. SleepType type
    )?,
  11. void onVad(
    1. VadEventType type, [
    2. int? volume
    ])?,
  12. void onCmdReturn(
    1. int cmd,
    2. int result,
    3. String? message
    )?,
  13. VoidCallback? onPreSleep,
  14. VoidCallback? onRecordStart,
  15. VoidCallback? onRecordStop,
  16. VoidCallback? onConnectedToServer,
  17. VoidCallback? onServerDisconnected,
  18. VoidCallback? onTts,
})

Implementation

AiuiEventListener({
  this.onResult,
  this.onIatResult,
  this.onNlpResult,
  this.onTppResult,
  this.onTtsResult,
  this.onITransResult,
  this.onError,
  this.onStateChange,
  this.onWakeup,
  this.onSleep,
  this.onVad,
  this.onCmdReturn,
  this.onPreSleep,
  this.onRecordStart,
  this.onRecordStop,
  this.onConnectedToServer,
  this.onServerDisconnected,
  this.onTts,
});