# Interface BackupOrBuilder (3.43.1)

3.43.1 (latest) 3.41.0 3.38.0 3.37.0 3.36.0 3.35.1 3.33.4 3.32.2 3.31.9 3.30.11 3.28.0 3.27.2 3.26.5 3.25.1 3.24.3 3.22.0 3.21.4 3.20.0 3.17.0 3.16.3 3.15.7 3.14.4 3.13.2 3.12.1 3.11.0 3.10.0 3.9.6 3.8.2 3.7.10 3.6.0 3.5.0 3.4.2 3.3.0 3.2.0 3.1.0 3.0.21

    public interface BackupOrBuilder extends MessageOrBuilder

## Implements

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

## Methods

### getDatabase()

    public abstract String getDatabase()

Output only. Name of the Firestore database that the backup is from.

Format is `projects/{project}/databases/{database}`.

`
string database = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
`

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

### getDatabaseBytes()

    public abstract ByteString getDatabaseBytes()

Output only. Name of the Firestore database that the backup is from.

Format is `projects/{project}/databases/{database}`.

`
string database = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
`

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

### getDatabaseUid()

    public abstract String getDatabaseUid()

Output only. The system-generated UUID4 for the Firestore database that the
backup is from.

`string database_uid = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];`

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

### getDatabaseUidBytes()

    public abstract ByteString getDatabaseUidBytes()

Output only. The system-generated UUID4 for the Firestore database that the
backup is from.

`string database_uid = 7 [(.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 databaseUid. |

### getExpireTime()

    public abstract Timestamp getExpireTime()

Output only. The timestamp at which this backup expires.

`.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### getExpireTimeOrBuilder()

    public abstract TimestampOrBuilder getExpireTimeOrBuilder()

Output only. The timestamp at which this backup expires.

`.google.protobuf.Timestamp expire_time = 4 [(.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. The unique resource name of the Backup.

Format is `projects/{project}/locations/{location}/backups/{backup}`.

The location in the name will be the Standard Managed Multi-Region (SMMR)
location (e.g. `us`) if the backup was created with an SMMR location, or
the Google Managed Multi-Region (GMMR) location (e.g. `nam5`) if the backup
was created with a GMMR location.

`string name = 1 [(.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. The unique resource name of the Backup.

Format is `projects/{project}/locations/{location}/backups/{backup}`.

The location in the name will be the Standard Managed Multi-Region (SMMR)
location (e.g. `us`) if the backup was created with an SMMR location, or
the Google Managed Multi-Region (GMMR) location (e.g. `nam5`) if the backup
was created with a GMMR location.

`string name = 1 [(.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. |

### getSnapshotTime()

    public abstract Timestamp getSnapshotTime()

Output only. The backup contains an externally consistent copy of the
database at this time.

`
.google.protobuf.Timestamp snapshot_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 snapshotTime. |

### getSnapshotTimeOrBuilder()

    public abstract TimestampOrBuilder getSnapshotTimeOrBuilder()

Output only. The backup contains an externally consistent copy of the
database at this time.

`
.google.protobuf.Timestamp snapshot_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` |   |

### getState()

    public abstract Backup.State getState()

Output only. The current state of the backup.

`
.google.firestore.admin.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### getStateValue()

    public abstract int getStateValue()

Output only. The current state of the backup.

`
.google.firestore.admin.v1.Backup.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### getStats()

    public abstract Backup.Stats getStats()

Output only. Statistics about the backup.

This data only becomes available after the backup is fully materialized to
secondary storage. This field will be empty till then.

`
.google.firestore.admin.v1.Backup.Stats stats = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-firestore/latest/com.google.firestore.admin.v1.Backup.Stats` | The stats. |

### getStatsOrBuilder()

    public abstract Backup.StatsOrBuilder getStatsOrBuilder()

Output only. Statistics about the backup.

This data only becomes available after the backup is fully materialized to
secondary storage. This field will be empty till then.

`
.google.firestore.admin.v1.Backup.Stats stats = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/java/docs/reference/google-cloud-firestore/latest/com.google.firestore.admin.v1.Backup.StatsOrBuilder` |   |

### hasExpireTime()

    public abstract boolean hasExpireTime()

Output only. The timestamp at which this backup expires.

`.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

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

### hasSnapshotTime()

    public abstract boolean hasSnapshotTime()

Output only. The backup contains an externally consistent copy of the
database at this time.

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

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

### hasStats()

    public abstract boolean hasStats()

Output only. Statistics about the backup.

This data only becomes available after the backup is fully materialized to
secondary storage. This field will be empty till then.

`
.google.firestore.admin.v1.Backup.Stats stats = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
`

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