pub fn list_filesystems(&self, fst: FsType) -> Vec<FS> {
        let args = [
            "list",
            "-Hp",
            "-o",
            &format!(
                "name,used,{op},{op}:{suf}",
                op = &self.option_name,
                suf = &self.label
            ),
            "-t",
            fst.to_str(),
        ];
        info!("zfs {}", args.join(" "));
        let ret = self
            .cmd()
            .args(&args)
            .output()
            .expect("failed to execute process");
        let stdout = String::from_utf8(ret.stdout).unwrap();
        let lines: Vec<FS> = stdout
            .split('\n')
            .filter(|l| l.len() > 0)
            .map(|t| str2fs(t, fst))
            .collect();
        lines
    }
/// Returns a list of the filesystems provided by the local zfs.
///
/// # Arguments
///
/// * fst - filesystem-type
///
Returns a list of the filesystems provided by the local zfs.
Returns a list of the filesystems provided by the local zfs .
pub fn list_filesystems(&self, fst: FsType) -> Vec<FS> {
        let args = [
            "list",
            "-Hp",
            "-o",
            &format!(
                "name,used,{op},{op}:{suf}",
                op = &self.option_name,
                suf = &self.label
            ),
            "-t",
            fst.to_str(),
        ];
        info!("zfs {}", args.join(" "));
        let ret = self
            .cmd()
            .args(&args)
            .output()
            .expect("failed to execute process");
        let stdout = String::from_utf8(ret.stdout).unwrap();
        let lines: Vec<FS> = stdout
            .split('\n')
            .filter(|l| l.len() > 0)
            .map(|t| str2fs(t, fst))
            .collect();
        lines
    }
pub fn list_filesystems ( & self , fst : FsType ) -> Vec < FS > { let args = [ " " , " " , " " , & format ! ( " " op self option_name suf self label ) , " " , fst . to_str ( ) , ] ; info ! ( " " args join ( " " ) ) ; let ret = self . cmd ( ) . args ( & args ) . output ( ) . expect ( " " ) ; let stdout = String :: from_utf8 ( ret . stdout ) . unwrap ( ) ; let lines : Vec < FS > = stdout . split ( '\n' ) . filter ( | l | l . len ( ) > 0 ) . map ( | t | str2fs ( t , fst ) ) . collect ( ) ; lines }
Returns a list of the filesystems provided by the local zfs.
Returns a list of the filesystems provided by the local zfs .
&self
fst
FsType
&self
fst
FsType