copyWith method

RealtimeTranslationSessionAudioInput copyWith({
  1. Object? transcription = unsetCopyWithValue,
  2. Object? noiseReduction = unsetCopyWithValue,
  3. bool? clearTranscription,
  4. bool? clearNoiseReduction,
})

Returns a copy of this with the given fields replaced.

Pass null for any nullable field to clear the in-memory value (use the clear* flags to send explicit JSON null over the wire).

Implementation

RealtimeTranslationSessionAudioInput copyWith({
  Object? transcription = unsetCopyWithValue,
  Object? noiseReduction = unsetCopyWithValue,
  bool? clearTranscription,
  bool? clearNoiseReduction,
}) => RealtimeTranslationSessionAudioInput(
  transcription: identical(transcription, unsetCopyWithValue)
      ? this.transcription
      : transcription as RealtimeTranslationInputTranscription?,
  noiseReduction: identical(noiseReduction, unsetCopyWithValue)
      ? this.noiseReduction
      : noiseReduction as RealtimeTranslationNoiseReduction?,
  clearTranscription: clearTranscription ?? this.clearTranscription,
  clearNoiseReduction: clearNoiseReduction ?? this.clearNoiseReduction,
);