# Interface MultiLanguageDetectionMetadataOrBuilder (0.34.0)

0.34.0 (latest) 0.32.0 0.29.0 0.28.0 0.26.0 0.24.0 0.23.0 0.21.0 0.19.0 0.17.0 0.16.0 0.15.0 0.14.0 0.13.0 0.11.0 0.9.0 0.8.0 0.5.0 0.4.0 0.3.0 0.1.0

    public interface MultiLanguageDetectionMetadataOrBuilder extends MessageOrBuilder

## Implements

[MessageOrBuilder](https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.MessageOrBuilder.html)

## Methods

### getEnableMultiLanguageDetection()

    public abstract boolean getEnableMultiLanguageDetection()

Optional. Enable detection of multi-language prompts and responses.

`bool enable_multi_language_detection = 2 [(.google.api.field_behavior) = OPTIONAL];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | The enableMultiLanguageDetection. |

### getSourceLanguage()

    public abstract String getSourceLanguage()

Optional. Optional Source language of the user prompt.

If multi-language detection is enabled and this field is not set, the
source language will be automatically detected. When a source language is
provided, Model Armor uses it to sanitize the input. In that case the
system does not perform auto-detection and relies solely on the specified
language.

This string field accepts a language code from the ISO-639 standard.
For a list of languages supported by Model Armor, see
[Model Armor supported languages](https://cloud.google.com/security-command-center/docs/model-armor-overview#languages-supported).
For a comprehensive list of language codes, see
[ISO-639](https://cloud.google.com/translate/docs/languages#nmt).

`string source_language = 1 [(.google.api.field_behavior) = OPTIONAL];`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` | The sourceLanguage. |

### getSourceLanguageBytes()

    public abstract ByteString getSourceLanguageBytes()

Optional. Optional Source language of the user prompt.

If multi-language detection is enabled and this field is not set, the
source language will be automatically detected. When a source language is
provided, Model Armor uses it to sanitize the input. In that case the
system does not perform auto-detection and relies solely on the specified
language.

This string field accepts a language code from the ISO-639 standard.
For a list of languages supported by Model Armor, see
[Model Armor supported languages](https://cloud.google.com/security-command-center/docs/model-armor-overview#languages-supported).
For a comprehensive list of language codes, see
[ISO-639](https://cloud.google.com/translate/docs/languages#nmt).

`string source_language = 1 [(.google.api.field_behavior) = OPTIONAL];`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.ByteString.html` | The bytes for sourceLanguage. |