TranslationResult

data class TranslationResult(val text: String, val translated: Boolean, val detectedLanguage: String? = null)

Result of Translator.translateToEnglish.

Parameters

text

the text to send to the server (the original when translated is false)

translated

true if text differs from the input because it was translated

detectedLanguage

language of the input (a hint or the detected one, for example fr), or null when unknown; it fills the x-language header

Constructors

Link copied to clipboard
constructor(text: String, translated: Boolean, detectedLanguage: String? = null)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard