# Google Cloud Storage Transfer V1 Client - Class GcsData (2.4.0)

2.4.0 (latest) 2.3.2 2.2.1 2.1.1 2.0.2 1.5.0 1.4.5 1.3.1 1.2.0 1.1.1 1.0.6 Reference documentation and code samples for the Google Cloud Storage Transfer V1 Client class GcsData.

In a GcsData resource, an object's name is the Cloud Storage object's
name and its "last modification time" refers to the object's `updated`
property of Cloud Storage objects, which changes when the content or the
metadata of the object is updated.

Generated from protobuf message `google.storagetransfer.v1.GcsData`

## Namespace

Google \\ Cloud \\ StorageTransfer \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ bucket_name` | `string` Required. Cloud Storage bucket name. Must meet [Bucket Name Requirements](https://docs.cloud.google.com/storage/docs/naming#requirements). |
| `↳ path` | `string` Root path to transfer objects. Must be an empty string or full path name that ends with a '/'. This field is treated as an object prefix. As such, it should generally not begin with a '/'. The root path value must meet [Object Name Requirements](https://docs.cloud.google.com/storage/docs/naming#objectnames). |
| `↳ managed_folder_transfer_enabled` | `bool` Preview. Enables the transfer of managed folders between Cloud Storage buckets. Set this option on the gcs_data_source. If set to true: - Managed folders in the source bucket are transferred to the destination bucket. - Managed folders in the destination bucket are overwritten. Other OVERWRITE options are not supported. See [Transfer Cloud Storage managed folders](https://docs.cloud.google.com/storage-transfer/docs/managed-folders). |

### getBucketName

Required. Cloud Storage bucket name. Must meet
[Bucket Name Requirements](https://docs.cloud.google.com/storage/docs/naming#requirements).

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

### setBucketName

Required. Cloud Storage bucket name. Must meet
[Bucket Name Requirements](https://docs.cloud.google.com/storage/docs/naming#requirements).

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

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

### getPath

Root path to transfer objects.

Must be an empty string or full path name that ends with a '/'. This field
is treated as an object prefix. As such, it should generally not begin with
a '/'.
The root path value must meet
[Object Name Requirements](https://docs.cloud.google.com/storage/docs/naming#objectnames).

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

### setPath

Root path to transfer objects.

Must be an empty string or full path name that ends with a '/'. This field
is treated as an object prefix. As such, it should generally not begin with
a '/'.
The root path value must meet
[Object Name Requirements](https://docs.cloud.google.com/storage/docs/naming#objectnames).

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

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

### getManagedFolderTransferEnabled

Preview. Enables the transfer of managed folders between Cloud Storage
buckets. Set this option on the gcs_data_source.

If set to true:

- Managed folders in the source bucket are transferred to the destination bucket.
- Managed folders in the destination bucket are overwritten. Other OVERWRITE options are not supported. See [Transfer Cloud Storage managed
  folders](https://docs.cloud.google.com/storage-transfer/docs/managed-folders).

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

### setManagedFolderTransferEnabled

Preview. Enables the transfer of managed folders between Cloud Storage
buckets. Set this option on the gcs_data_source.

If set to true:

- Managed folders in the source bucket are transferred to the destination bucket.
- Managed folders in the destination bucket are overwritten. Other OVERWRITE options are not supported. See [Transfer Cloud Storage managed
  folders](https://docs.cloud.google.com/storage-transfer/docs/managed-folders).

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

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