Builder
class Builder
| kotlin.Any | |
| ↳ | android.view.translation.TranslationResponseValue.Builder | 
A builder for TranslationResponseValue
Summary
| Public constructors | |
|---|---|
| Creates a new Builder. | |
| Public methods | |
|---|---|
| TranslationResponseValue | build()Builds the instance. | 
| TranslationResponseValue.Builder | Extra results associated with the translated text. | 
| TranslationResponseValue.Builder | setText(value: CharSequence)The translated text result. | 
| TranslationResponseValue.Builder | setTransliteration(value: CharSequence)The transliteration result of the translated text. | 
Public constructors
Builder
Builder(statusCode: Int)
Creates a new Builder.
| Parameters | |
|---|---|
| statusCode | Int: The status code of this TranslationResponseValue.If the status code is  | 
Public methods
build
fun build(): TranslationResponseValue
Builds the instance. This builder should not be touched after calling this!
| Return | |
|---|---|
| TranslationResponseValue | This value cannot be null. | 
setExtras
fun setExtras(value: Bundle): TranslationResponseValue.Builder
Extra results associated with the translated text.
The bundle includes EXTRA_DEFINITIONS, obtained by Bundle.getBundle. 
| Parameters | |
|---|---|
| value | Bundle: This value cannot be null. | 
| Return | |
|---|---|
| TranslationResponseValue.Builder | This value cannot be null. | 
setText
fun setText(value: CharSequence): TranslationResponseValue.Builder
The translated text result.
| Parameters | |
|---|---|
| value | CharSequence: This value cannot be null. | 
| Return | |
|---|---|
| TranslationResponseValue.Builder | This value cannot be null. | 
setTransliteration
fun setTransliteration(value: CharSequence): TranslationResponseValue.Builder
The transliteration result of the translated text.
This returns a CharSequence representation of the transliteration of the translated text.
| Parameters | |
|---|---|
| value | CharSequence: This value cannot be null. | 
| Return | |
|---|---|
| TranslationResponseValue.Builder | This value cannot be null. | 
