# Interface StreamOrBuilder (1.92.0)

1.92.0 (latest) 1.90.0 1.87.0 1.86.0 1.84.0 1.82.0 1.81.0 1.80.0 1.79.0 1.77.0 1.75.0 1.74.0 1.73.0 1.72.0 1.71.0 1.69.0 1.67.0 1.66.0 1.63.0 1.62.0 1.61.0 1.59.0 1.58.0 1.57.0 1.56.0 1.55.0 1.54.0 1.53.0 1.52.0 1.51.0 1.50.0 1.48.0 1.47.0 1.46.0 1.45.0 1.44.0 1.43.0 1.42.0 1.41.0 1.40.0 1.39.0 1.38.0 1.36.0 1.35.0 1.34.0 1.33.0 1.32.0 1.31.0 1.30.0 1.29.0 1.28.0 1.27.0 1.26.0 1.23.0 1.22.0 1.21.0 1.20.0 1.19.0 1.18.0 1.17.0 1.16.0 1.15.0 1.14.0 1.13.0 1.12.0 1.11.0 1.10.0 1.8.0 1.7.0 1.6.0 1.5.0 1.4.0 1.3.0 1.2.2 1.1.1 1.0.0 0.4.2

    public interface StreamOrBuilder extends MessageOrBuilder

## Implements

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

## Methods

### containsLabels(String key)

    public abstract boolean containsLabels(String key)

Labels.

`map<string, string> labels = 4;`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `key` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` |

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

### getBackfillAll()

    public abstract Stream.BackfillAllStrategy getBackfillAll()

Automatically backfill objects included in the stream source
configuration. Specific objects can be excluded.

`.google.cloud.datastream.v1.Stream.BackfillAllStrategy backfill_all = 101;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Stream.BackfillAllStrategy` | The backfillAll. |

### getBackfillAllOrBuilder()

    public abstract Stream.BackfillAllStrategyOrBuilder getBackfillAllOrBuilder()

Automatically backfill objects included in the stream source
configuration. Specific objects can be excluded.

`.google.cloud.datastream.v1.Stream.BackfillAllStrategy backfill_all = 101;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Stream.BackfillAllStrategyOrBuilder` |   |

### getBackfillNone()

    public abstract Stream.BackfillNoneStrategy getBackfillNone()

Do not automatically backfill any objects.

`.google.cloud.datastream.v1.Stream.BackfillNoneStrategy backfill_none = 102;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Stream.BackfillNoneStrategy` | The backfillNone. |

### getBackfillNoneOrBuilder()

    public abstract Stream.BackfillNoneStrategyOrBuilder getBackfillNoneOrBuilder()

Do not automatically backfill any objects.

`.google.cloud.datastream.v1.Stream.BackfillNoneStrategy backfill_none = 102;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Stream.BackfillNoneStrategyOrBuilder` |   |

### getBackfillStrategyCase()

    public abstract Stream.BackfillStrategyCase getBackfillStrategyCase()

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Stream.BackfillStrategyCase` |   |

### getCreateTime()

    public abstract Timestamp getCreateTime()

Output only. The creation time of the stream.

`.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.Timestamp.html` | The createTime. |

### getCreateTimeOrBuilder()

    public abstract TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The creation time of the stream.

`.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.TimestampOrBuilder.html` |   |

### getCustomerManagedEncryptionKey()

    public abstract String getCustomerManagedEncryptionKey()

Immutable. A reference to a KMS encryption key.
If provided, it will be used to encrypt the data.
If left blank, data will be encrypted using an internal Stream-specific
encryption key provisioned through KMS.

`
optional string customer_managed_encryption_key = 10 [(.google.api.field_behavior) = IMMUTABLE];
`

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

### getCustomerManagedEncryptionKeyBytes()

    public abstract ByteString getCustomerManagedEncryptionKeyBytes()

Immutable. A reference to a KMS encryption key.
If provided, it will be used to encrypt the data.
If left blank, data will be encrypted using an internal Stream-specific
encryption key provisioned through KMS.

`
optional string customer_managed_encryption_key = 10 [(.google.api.field_behavior) = IMMUTABLE];
`

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

### getDestinationConfig()

    public abstract DestinationConfig getDestinationConfig()

Required. Destination connection profile configuration.

`
.google.cloud.datastream.v1.DestinationConfig destination_config = 7 [(.google.api.field_behavior) = REQUIRED];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.DestinationConfig` | The destinationConfig. |

### getDestinationConfigOrBuilder()

    public abstract DestinationConfigOrBuilder getDestinationConfigOrBuilder()

Required. Destination connection profile configuration.

`
.google.cloud.datastream.v1.DestinationConfig destination_config = 7 [(.google.api.field_behavior) = REQUIRED];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.DestinationConfigOrBuilder` |   |

### getDisplayName()

    public abstract String getDisplayName()

Required. Display name.

`string display_name = 5 [(.google.api.field_behavior) = REQUIRED];`

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

### getDisplayNameBytes()

    public abstract ByteString getDisplayNameBytes()

Required. Display name.

`string display_name = 5 [(.google.api.field_behavior) = REQUIRED];`

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

### getErrors(int index)

    public abstract Error getErrors(int index)

Output only. Errors on the Stream.

`
repeated .google.cloud.datastream.v1.Error errors = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `index` | `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Error` |   |

### getErrorsCount()

    public abstract int getErrorsCount()

Output only. Errors on the Stream.

`
repeated .google.cloud.datastream.v1.Error errors = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### getErrorsList()

    public abstract List<Error> getErrorsList()

Output only. Errors on the Stream.

`
repeated .google.cloud.datastream.v1.Error errors = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/util/List.html<https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Error>` |   |

### getErrorsOrBuilder(int index)

    public abstract ErrorOrBuilder getErrorsOrBuilder(int index)

Output only. Errors on the Stream.

`
repeated .google.cloud.datastream.v1.Error errors = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `index` | `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.ErrorOrBuilder` |   |

### getErrorsOrBuilderList()

    public abstract List<? extends ErrorOrBuilder> getErrorsOrBuilderList()

Output only. Errors on the Stream.

`
repeated .google.cloud.datastream.v1.Error errors = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/util/List.html<? extends com.google.cloud.datastream.v1.ErrorOrBuilder>` |   |

### getLabels() (deprecated)

    public abstract Map<String,String> getLabels()

Use [#getLabelsMap()](https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.StreamOrBuilder#com_google_cloud_datastream_v1_StreamOrBuilder_getLabelsMap__) instead.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/util/Map.html<https://docs.oracle.com/javase/8/docs/api/java/lang/String.html,https://docs.oracle.com/javase/8/docs/api/java/lang/String.html>` |   |

### getLabelsCount()

    public abstract int getLabelsCount()

Labels.

`map<string, string> labels = 4;`

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

### getLabelsMap()

    public abstract Map<String,String> getLabelsMap()

Labels.

`map<string, string> labels = 4;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/8/docs/api/java/util/Map.html<https://docs.oracle.com/javase/8/docs/api/java/lang/String.html,https://docs.oracle.com/javase/8/docs/api/java/lang/String.html>` |   |

### getLabelsOrDefault(String key, String defaultValue)

    public abstract String getLabelsOrDefault(String key, String defaultValue)

Labels.

`map<string, string> labels = 4;`

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `key` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` |
| `defaultValue` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` |

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

### getLabelsOrThrow(String key)

    public abstract String getLabelsOrThrow(String key)

Labels.

`map<string, string> labels = 4;`

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `key` | `https://docs.oracle.com/javase/8/docs/api/java/lang/String.html` |

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

### getLastRecoveryTime()

    public abstract Timestamp getLastRecoveryTime()

Output only. If the stream was recovered, the time of the last recovery.
Note: This field is currently experimental.

`
.google.protobuf.Timestamp last_recovery_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.Timestamp.html` | The lastRecoveryTime. |

### getLastRecoveryTimeOrBuilder()

    public abstract TimestampOrBuilder getLastRecoveryTimeOrBuilder()

Output only. If the stream was recovered, the time of the last recovery.
Note: This field is currently experimental.

`
.google.protobuf.Timestamp last_recovery_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.TimestampOrBuilder.html` |   |

### getName()

    public abstract String getName()

Output only. Identifier. The stream's name.

`
string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### getNameBytes()

    public abstract ByteString getNameBytes()

Output only. Identifier. The stream's name.

`
string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### getSatisfiesPzi()

    public abstract boolean getSatisfiesPzi()

Output only. Reserved for future use.

`optional bool satisfies_pzi = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];`

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

### getSatisfiesPzs()

    public abstract boolean getSatisfiesPzs()

Output only. Reserved for future use.

`optional bool satisfies_pzs = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];`

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

### getSourceConfig()

    public abstract SourceConfig getSourceConfig()

Required. Source connection profile configuration.

`
.google.cloud.datastream.v1.SourceConfig source_config = 6 [(.google.api.field_behavior) = REQUIRED];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.SourceConfig` | The sourceConfig. |

### getSourceConfigOrBuilder()

    public abstract SourceConfigOrBuilder getSourceConfigOrBuilder()

Required. Source connection profile configuration.

`
.google.cloud.datastream.v1.SourceConfig source_config = 6 [(.google.api.field_behavior) = REQUIRED];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.SourceConfigOrBuilder` |   |

### getState()

    public abstract Stream.State getState()

The state of the stream.

`.google.cloud.datastream.v1.Stream.State state = 8;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-datastream/latest/com.google.cloud.datastream.v1.Stream.State` | The state. |

### getStateValue()

    public abstract int getStateValue()

The state of the stream.

`.google.cloud.datastream.v1.Stream.State state = 8;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | The enum numeric value on the wire for state. |

### getUpdateTime()

    public abstract Timestamp getUpdateTime()

Output only. The last update time of the stream.

`.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.Timestamp.html` | The updateTime. |

### getUpdateTimeOrBuilder()

    public abstract TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. The last update time of the stream.

`.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.TimestampOrBuilder.html` |   |

### hasBackfillAll()

    public abstract boolean hasBackfillAll()

Automatically backfill objects included in the stream source
configuration. Specific objects can be excluded.

`.google.cloud.datastream.v1.Stream.BackfillAllStrategy backfill_all = 101;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the backfillAll field is set. |

### hasBackfillNone()

    public abstract boolean hasBackfillNone()

Do not automatically backfill any objects.

`.google.cloud.datastream.v1.Stream.BackfillNoneStrategy backfill_none = 102;`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the backfillNone field is set. |

### hasCreateTime()

    public abstract boolean hasCreateTime()

Output only. The creation time of the stream.

`.google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the createTime field is set. |

### hasCustomerManagedEncryptionKey()

    public abstract boolean hasCustomerManagedEncryptionKey()

Immutable. A reference to a KMS encryption key.
If provided, it will be used to encrypt the data.
If left blank, data will be encrypted using an internal Stream-specific
encryption key provisioned through KMS.

`
optional string customer_managed_encryption_key = 10 [(.google.api.field_behavior) = IMMUTABLE];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the customerManagedEncryptionKey field is set. |

### hasDestinationConfig()

    public abstract boolean hasDestinationConfig()

Required. Destination connection profile configuration.

`
.google.cloud.datastream.v1.DestinationConfig destination_config = 7 [(.google.api.field_behavior) = REQUIRED];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the destinationConfig field is set. |

### hasLastRecoveryTime()

    public abstract boolean hasLastRecoveryTime()

Output only. If the stream was recovered, the time of the last recovery.
Note: This field is currently experimental.

`
.google.protobuf.Timestamp last_recovery_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the lastRecoveryTime field is set. |

### hasSatisfiesPzi()

    public abstract boolean hasSatisfiesPzi()

Output only. Reserved for future use.

`optional bool satisfies_pzi = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the satisfiesPzi field is set. |

### hasSatisfiesPzs()

    public abstract boolean hasSatisfiesPzs()

Output only. Reserved for future use.

`optional bool satisfies_pzs = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the satisfiesPzs field is set. |

### hasSourceConfig()

    public abstract boolean hasSourceConfig()

Required. Source connection profile configuration.

`
.google.cloud.datastream.v1.SourceConfig source_config = 6 [(.google.api.field_behavior) = REQUIRED];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the sourceConfig field is set. |

### hasUpdateTime()

    public abstract boolean hasUpdateTime()

Output only. The last update time of the stream.

`.google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.oracle.com/javase/tutorial/java/nutsandbolts/datatypes.html` | Whether the updateTime field is set. |