Trait scsys_core::specs::Contain
source · pub trait Contain<T>where
T: PartialEq,{
// Required method
fn contains(&self, elem: &T) -> bool;
// Provided methods
fn contains_all(&self, iter: impl IntoIterator<Item = T>) -> bool { ... }
fn contains_some(&self, iter: impl IntoIterator<Item = T>) -> bool { ... }
}
Expand description
Interface for data-structures that can be compared for equality
Required Methods§
Provided Methods§
sourcefn contains_all(&self, iter: impl IntoIterator<Item = T>) -> bool
fn contains_all(&self, iter: impl IntoIterator<Item = T>) -> bool
Contain::contains_all returns true if all elements in the given iterator are in the Contain instance
sourcefn contains_some(&self, iter: impl IntoIterator<Item = T>) -> bool
fn contains_some(&self, iter: impl IntoIterator<Item = T>) -> bool
Contain::contains_some returns true if any element in the given iterator is in the Contain instance
Object Safety§
This trait is not object safe.