# Cloud Translation V3 Client - Class DocumentInputConfig (2.3.0)

2.3.0 (latest) 2.2.0 2.1.2 2.0.3 1.21.0 1.20.2 1.19.0 1.18.1 1.17.7 1.16.0 1.15.4 1.14.3 1.13.3 1.12.12 Reference documentation and code samples for the Cloud Translation V3 Client class DocumentInputConfig.

A document translation request input config.

Generated from protobuf message `google.cloud.translation.v3.DocumentInputConfig`

## Namespace

Google \\ Cloud \\ Translate \\ V3

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ content` | `string` Document's content represented as a stream of bytes. |
| `↳ gcs_source` | `https://docs.cloud.google.com/php/docs/reference/cloud-translate/latest/V3.GcsSource` Google Cloud Storage location. This must be a single file. For example: gs://example_bucket/example_file.pdf |
| `↳ mime_type` | `string` Specifies the input document's mime_type. If not specified it will be determined using the file extension for gcs_source provided files. For a file provided through bytes content the mime_type must be provided. Currently supported mime types are: - application/pdf - application/vnd.openxmlformats-officedocument.wordprocessingml.document - application/vnd.openxmlformats-officedocument.presentationml.presentation - application/vnd.openxmlformats-officedocument.spreadsheetml.sheet |

### getContent

Document's content represented as a stream of bytes.

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

### hasContent

### setContent

Document's content represented as a stream of bytes.

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

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

### getGcsSource

Google Cloud Storage location. This must be a single file.

For example: gs://example_bucket/example_file.pdf

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-translate/latest/V3.GcsSource|null` |   |

### hasGcsSource

### setGcsSource

Google Cloud Storage location. This must be a single file.

For example: gs://example_bucket/example_file.pdf

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-translate/latest/V3.GcsSource` |

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

### getMimeType

Specifies the input document's mime_type.

If not specified it will be determined using the file extension for
gcs_source provided files. For a file provided through bytes content the
mime_type must be provided.
Currently supported mime types are:

- application/pdf
- application/vnd.openxmlformats-officedocument.wordprocessingml.document
- application/vnd.openxmlformats-officedocument.presentationml.presentation
- application/vnd.openxmlformats-officedocument.spreadsheetml.sheet

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

### setMimeType

Specifies the input document's mime_type.

If not specified it will be determined using the file extension for
gcs_source provided files. For a file provided through bytes content the
mime_type must be provided.
Currently supported mime types are:

- application/pdf
- application/vnd.openxmlformats-officedocument.wordprocessingml.document
- application/vnd.openxmlformats-officedocument.presentationml.presentation
- application/vnd.openxmlformats-officedocument.spreadsheetml.sheet

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

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

### getSource

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