TranslationVerboseResponse class

A verbose translation response with additional metadata.

Includes segment-level timestamps.

Annotations
  • @immutable

Constructors

TranslationVerboseResponse({required String task, required String language, required double duration, required String text, List<TranscriptionSegment>? segments})
Creates a TranslationVerboseResponse.
const
TranslationVerboseResponse.fromJson(Map<String, dynamic> json)
Creates a TranslationVerboseResponse from JSON.
factory

Properties

duration double
The duration of the audio in seconds.
final
hashCode int
The hash code for this object.
no setteroverride
language String
The detected source language.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
segments List<TranscriptionSegment>?
Segments with timestamps.
final
task String
The task performed (always "translate").
final
text String
The full translated text.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts to JSON.
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
override