Expand description
Represents a entry which can either be a directory with more entries, or a singular file.
Variants§
Implementations§
source§impl<T> Entry<T>
impl<T> Entry<T>
pub fn new() -> Self
sourcepub fn build_with<U>(
values: impl IntoIterator<Item = U>,
k: impl Fn(&U) -> Vec<String>,
v: impl Fn(&str, U) -> T
) -> Self
pub fn build_with<U>(
values: impl IntoIterator<Item = U>,
k: impl Fn(&U) -> Vec<String>,
v: impl Fn(&str, U) -> T
) -> Self
Helper which can turn a collection of values into a tree. The caller must supply a closure which extracts a key from a value.
Trait Implementations§
source§impl<T: PartialEq> PartialEq<Entry<T>> for Entry<T>
impl<T: PartialEq> PartialEq<Entry<T>> for Entry<T>
impl<T: Eq> Eq for Entry<T>
impl<T> StructuralEq for Entry<T>
impl<T> StructuralPartialEq for Entry<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for Entry<T>where
T: RefUnwindSafe,
impl<T> Send for Entry<T>where
T: Send,
impl<T> Sync for Entry<T>where
T: Sync,
impl<T> Unpin for Entry<T>where
T: Unpin,
impl<T> UnwindSafe for Entry<T>where
T: UnwindSafe,
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.