# Google Cloud Datastore Admin V1 Client - Class MigrationStateEvent (1.1.2)

1.1.2 (latest) 1.1.1 1.0.4 0.8.5 0.7.5 0.6.0 0.5.8 Reference documentation and code samples for the Google Cloud Datastore Admin V1 Client class MigrationStateEvent.

An event signifying a change in state of a [migration from Cloud Datastore to
Cloud Firestore in Datastore
mode](https://cloud.google.com/datastore/docs/upgrade-to-firestore).

Generated from protobuf message `google.datastore.admin.v1.MigrationStateEvent`

## Namespace

Google \\ Cloud \\ Datastore \\ Admin \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ state` | `int` The new state of the migration. |

### getState

The new state of the migration.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [MigrationState](https://docs.cloud.google.com/php/docs/reference/cloud-datastore-admin/latest/V1.MigrationState). |

### setState

The new state of the migration.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [MigrationState](https://docs.cloud.google.com/php/docs/reference/cloud-datastore-admin/latest/V1.MigrationState). |

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