pub struct TreeReport {
pub root: PathBuf,
pub files: usize,
pub dirs: usize,
pub long_names: usize,
pub skipped: Vec<SkippedEntry>,
}Expand description
树形模式加密的结果。
Fields§
§root: PathBuf加密后的根目录(磁盘路径,名字已加密)。
files: usize成功加密的文件数。
dirs: usize创建的目录数。
long_names: usize需要边车文件才能还原的超长目录名数量。
单独报出来是因为它有运维含义:这些目录一旦丢了 .omy-name
就再也认不出原名,用户可能想缩短目录层级重来一次。
skipped: Vec<SkippedEntry>被跳过的条目,需如实展示。
Implementations§
Source§impl TreeReport
impl TreeReport
Sourcepub const fn leak_notice() -> &'static str
pub const fn leak_notice() -> &'static str
树形模式泄露元数据的统一告知文案(N6)。
放在 core 而不是各前端:CLI 与 GUI 说法不一致会让人以为是两种不同的 行为。措辞刻意具体——「泄露元数据」这种说法用户无法据此判断风险, 「别人能数出你有多少文件」才能。
Trait Implementations§
Source§impl Debug for TreeReport
impl Debug for TreeReport
Auto Trait Implementations§
impl Forget for TreeReport
impl Freeze for TreeReport
impl RefUnwindSafe for TreeReport
impl Send for TreeReport
impl Sync for TreeReport
impl Unpin for TreeReport
impl UnsafeUnpin for TreeReport
impl UnwindSafe for TreeReport
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more