0.10.0 (latest) 0.9.0 0.8.4 0.7.0 0.6.0 0.5.3 0.4.0 0.3.1 0.2.0 0.1.0

> [!WARNING]
> **Beta**
>
>
> This library is covered by the [Pre-GA Offerings Terms](https://docs.cloud.google.com/terms/service-terms#1)
> of the Terms of Service. Pre-GA libraries might have limited support,
> and changes to pre-GA libraries might not be compatible with other pre-GA versions.
> For more information, see the
> [launch stage descriptions](https://docs.cloud.google.com/products#product-launch-stages).

Reference documentation and code samples for the Google Cloud Model Armor V1beta Client class MultiLanguageDetectionMetadata.

Message for Enabling Multi Language Detection.

Generated from protobuf message `google.cloud.modelarmor.v1beta.MultiLanguageDetectionMetadata`

## Namespace

Google \\ Cloud \\ ModelArmor \\ V1beta

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ source_language` | `string` 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). |
| `↳ enable_multi_language_detection` | `bool` Optional. Enable detection of multi-language prompts and responses. |

### 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).

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setSourceLanguage

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).

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getEnableMultiLanguageDetection

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

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setEnableMultiLanguageDetection

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

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |