BackupDir: add group/dir accessors
for getting the respective api type references for convenient printing/logging. Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
This commit is contained in:
parent
90915ab629
commit
f15601f1c9
|
@ -369,6 +369,14 @@ impl BackupDir {
|
|||
&self.backup_time_string
|
||||
}
|
||||
|
||||
pub fn dir(&self) -> &pbs_api_types::BackupDir {
|
||||
&self.dir
|
||||
}
|
||||
|
||||
pub fn group(&self) -> &pbs_api_types::BackupGroup {
|
||||
&self.dir.group
|
||||
}
|
||||
|
||||
pub fn relative_path(&self) -> PathBuf {
|
||||
let mut path = self.ns.path();
|
||||
path.push(self.dir.group.ty.as_str());
|
||||
|
|
Loading…
Reference in New Issue