pub struct CacheDir {
pub prefix: DirPrefix,
pub path: String,
}
Fields§
§prefix: DirPrefix
§path: String
Implementations§
Source§impl CacheDir
impl CacheDir
Sourcepub const XDG_ENV: &'static str = "XDG_CACHE_HOME"
pub const XDG_ENV: &'static str = "XDG_CACHE_HOME"
Environment variable name which used xdg
prefix
Sourcepub const XDG_FALLBACK_PATH: &'static str = "~/.cache"
pub const XDG_FALLBACK_PATH: &'static str = "~/.cache"
Fallback path when XDG_ENV
is not exists
const DEFAULT_PREFIX_BEHAVIOR: PrefixBehavior = PrefixBehavior::Cwd
fn get_prefix_behavior(prefix: DirPrefix) -> PrefixBehavior
Trait Implementations§
Source§impl From<CacheDir> for ConfigPart
impl From<CacheDir> for ConfigPart
impl Eq for CacheDir
impl StructuralPartialEq for CacheDir
Auto Trait Implementations§
impl Freeze for CacheDir
impl RefUnwindSafe for CacheDir
impl Send for CacheDir
impl Sync for CacheDir
impl Unpin for CacheDir
impl UnwindSafe for CacheDir
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