AI-generated Key Takeaways
- 
          TranslatorOptions.Builder is a builder used to create a TranslatorOptions instance. 
- 
          The build method creates a new TranslatorOptions instance, requiring source and target languages to be set beforehand. 
- 
          You can optionally set a custom Executor for the builder using the setExecutor method. 
- 
          The setSourceLanguage method sets the language to translate from, using a BCP 47 tag. 
- 
          The setTargetLanguage method sets the language to translate to, using a BCP 47 tag. 
Builder to create a TranslatorOptions
      instance.
Public Constructor Summary
| 
                  
                  Builder()
                 | 
Public Method Summary
| TranslatorOptions | 
                  
                  build()
                   
                    Creates a new  TranslatorOptionsinstance. | 
| TranslatorOptions.Builder | |
| TranslatorOptions.Builder | |
| TranslatorOptions.Builder | 
Inherited Method Summary
Public Constructors
public Builder ()
Public Methods
public TranslatorOptions build ()
Creates a new TranslatorOptions
            instance. The source and target language should be set before calling this method.
public TranslatorOptions.Builder setExecutor (Executor executor)
public TranslatorOptions.Builder setSourceLanguage (String sourceLanguage)
Sets the language to translate from.
Parameters
| sourceLanguage | the BCP 47 tag of the language to
                  translate from. The value must be one of the possible values for 
                  TranslateLanguage.Language). | 
|---|
Returns
- this object, for chaining method calls
public TranslatorOptions.Builder setTargetLanguage (String targetLanguage)
Sets the language to translate to.
Parameters
| targetLanguage | the BCP 47 tag of the language to
                  translate to. The value must be one of the possible values for 
                  TranslateLanguage.Language). | 
|---|
Returns
- this object, for chaining method calls
