#[non_exhaustive]pub struct Backup {
pub name: String,
pub database: String,
pub database_uid: String,
pub snapshot_time: Option<Timestamp>,
pub expire_time: Option<Timestamp>,
pub stats: Option<Stats>,
pub state: State,
/* private fields */
}Expand description
A Backup of a Cloud Firestore Database.
The backup contains all documents and index configurations for the given database at a specific point in time.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringOutput only. The unique resource name of the Backup.
Format is projects/{project}/locations/{location}/backups/{backup}.
database: StringOutput only. Name of the Firestore database that the backup is from.
Format is projects/{project}/databases/{database}.
database_uid: StringOutput only. The system-generated UUID4 for the Firestore database that the backup is from.
snapshot_time: Option<Timestamp>Output only. The backup contains an externally consistent copy of the database at this time.
expire_time: Option<Timestamp>Output only. The timestamp at which this backup expires.
stats: Option<Stats>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.
state: StateOutput only. The current state of the backup.
Implementations§
Source§impl Backup
impl Backup
pub fn new() -> Self
Sourcepub fn set_database<T: Into<String>>(self, v: T) -> Self
pub fn set_database<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_database_uid<T: Into<String>>(self, v: T) -> Self
pub fn set_database_uid<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_snapshot_time<T>(self, v: T) -> Self
pub fn set_snapshot_time<T>(self, v: T) -> Self
Sets the value of snapshot_time.
§Example
use wkt::Timestamp;
let x = Backup::new().set_snapshot_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_snapshot_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_snapshot_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of snapshot_time.
§Example
use wkt::Timestamp;
let x = Backup::new().set_or_clear_snapshot_time(Some(Timestamp::default()/* use setters */));
let x = Backup::new().set_or_clear_snapshot_time(None::<Timestamp>);Sourcepub fn set_expire_time<T>(self, v: T) -> Self
pub fn set_expire_time<T>(self, v: T) -> Self
Sets the value of expire_time.
§Example
use wkt::Timestamp;
let x = Backup::new().set_expire_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_expire_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_expire_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of expire_time.
§Example
use wkt::Timestamp;
let x = Backup::new().set_or_clear_expire_time(Some(Timestamp::default()/* use setters */));
let x = Backup::new().set_or_clear_expire_time(None::<Timestamp>);