[−][src]Struct dashcache::arr::CachedArr
A cached array satisfying a given predicate P
Implementations
impl<A, P, H> CachedArr<A, P, H>
[src]
pub fn as_ptr(&self) -> *const A
[src]
Get the pointer to the first element of this CachedArr
, or null if there is none (i.e. the slice is empty)
pub fn as_slice(&self) -> &[A]
[src]
Get the slice underlying this CachedArr
pub fn iter(&self) -> Iter<'_, A>
[src]
Iterate over the items of this CachedArr
pub fn as_arr(&self) -> &CachedArr<A, (), H>
[src]
Strip the predicate from this CachedArr
pub fn into_arr(self) -> CachedArr<A, (), H>
[src]
Strip the predicate from this CachedArr
, consuming it.
pub fn coerce<Q>(self) -> CachedArr<A, Q, H>
[src]
Coerce this array into one satisfying another predicate
pub fn coerce_ref<Q>(&self) -> &CachedArr<A, Q, H>
[src]
Coerce this array as a reference into one satisfying another predicate
impl<A> CachedArr<A>
[src]
pub fn from_exact<I: ExactSizeIterator + Iterator<Item = A>>(
iter: I
) -> CachedArr<A>
[src]
iter: I
) -> CachedArr<A>
Create a new cached array from an exact length iterator
impl<A, P: EmptyPredicate> CachedArr<A, P>
[src]
impl<A: Deref, P, H> CachedArr<A, P, H>
[src]
pub fn is_sorted(&self) -> bool
[src]
Check if this array is sorted by address
pub fn is_set(&self) -> bool
[src]
Check if this array is strictly sorted by address
pub fn try_as_bag(&self) -> Result<&CachedBag<A, H>, &Self>
[src]
Try to cast this array into a bag if sorted
pub fn try_as_set(&self) -> Result<&CachedSet<A, H>, &Self>
[src]
Try to cast this array into a set if strictly sorted
pub fn sorted(&self) -> CachedBag<A> where
A: Clone,
[src]
A: Clone,
Sort this array and return it
pub fn set(&self) -> CachedSet<A> where
A: Clone,
[src]
A: Clone,
Sort and deduplicate this array and return it
pub fn try_into_bag(self) -> Result<CachedBag<A, H>, Self>
[src]
Try to cast this array into a bag if sorted
pub fn try_into_set(self) -> Result<CachedSet<A, H>, Self>
[src]
Try to cast this array into a set if strictly sorted
impl<A: Deref, P: BagMarker, H> CachedArr<A, P, H>
[src]
pub fn as_bag(&self) -> &CachedBag<A, H>
[src]
Cast this array into a bag
pub fn into_bag(self) -> CachedBag<A, H>
[src]
Cast this array into a bag
impl<A: Deref, P: SetMarker, H> CachedArr<A, P, H>
[src]
pub fn as_set(&self) -> &CachedSet<A, H>
[src]
Cast this array into a set
pub fn into_set(self) -> CachedSet<A, H>
[src]
Cast this array into a set
impl<A: Deref + Clone, H> CachedArr<A, Sorted, H>
[src]
pub fn contains_impl(&self, item: *const A::Target) -> Option<&A>
[src]
Check whether an item is in this bag. If it is, return a reference.
pub fn uniq_impl(&self) -> CachedSet<A>
[src]
Deduplicate this bag into a set
impl<A: Deref + Clone> CachedArr<A, Sorted, H>
[src]
pub fn merge_impl(&self, rhs: &CachedBag<A>) -> CachedBag<A>
[src]
Merge two bags
pub fn intersect_impl(&self, rhs: &CachedBag<A>) -> CachedBag<A>
[src]
Take the intersection of two bags
impl<A: Deref + Clone, P: BagMarker, H> CachedArr<A, P, H>
[src]
pub fn contains(&self, item: *const A::Target) -> Option<&A>
[src]
Check whether an item is in this bag. If it is, return a reference.
impl<A: Deref + Clone, P: BagMarker> CachedArr<A, P>
[src]
pub fn merge<Q: BagMarker>(&self, rhs: &CachedArr<A, Q>) -> CachedBag<A>
[src]
Merge two bags
pub fn intersect<Q: BagMarker>(&self, rhs: &CachedArr<A, Q>) -> CachedArr<A, P>
[src]
Take the intersection of two bags
pub fn uniq(&self) -> CachedSet<A>
[src]
Deduplicate this bag into a set
impl<A: Deref + Clone> CachedArr<A, Uniq, H>
[src]
pub fn union_impl(&self, rhs: &CachedSet<A>) -> CachedSet<A>
[src]
Take the union of two sets
impl<A: Deref + Clone, P: SetMarker> CachedArr<A, P>
[src]
pub fn union<Q: SetMarker>(&self, rhs: &CachedArr<A, Q>) -> CachedSet<A>
[src]
Take the union of two sets
Trait Implementations
impl<A: Eq + Deref, P> Caches<[A]> for CachedArr<A, P>
[src]
impl<A: Eq + Deref, P> CanCollect for CachedArr<A, P>
[src]
fn can_collect(&self) -> bool
[src]
fn can_collect_clone(&self) -> bool
[src]
impl<A, P, H> Clone for CachedArr<A, P, H>
[src]
impl<A, P> Debug for CachedArr<A, P> where
A: Debug,
[src]
A: Debug,
impl<A, P: EmptyPredicate> Default for CachedArr<A, P>
[src]
impl<A, P> Deref for CachedArr<A, P>
[src]
impl<A: Deref, P, H> Eq for CachedArr<A, P, H>
[src]
impl<A: Clone, '_> From<&'_ [A]> for CachedArr<A>
[src]
impl<A> From<Vec<A>> for CachedArr<A>
[src]
impl<A> FromIterator<A> for CachedArr<A>
[src]
fn from_iter<I: IntoIterator<Item = A>>(iter: I) -> CachedArr<A>
[src]
impl<A, P> Hash for CachedArr<A, P> where
A: Deref,
[src]
A: Deref,
fn hash<H: Hasher>(&self, hasher: &mut H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl<A: Deref, P, Q, H> PartialEq<CachedArr<A, P, H>> for CachedArr<A, Q, H>
[src]
Auto Trait Implementations
impl<A, P, H> RefUnwindSafe for CachedArr<A, P, H> where
A: RefUnwindSafe,
H: RefUnwindSafe,
P: RefUnwindSafe,
A: RefUnwindSafe,
H: RefUnwindSafe,
P: RefUnwindSafe,
impl<A, P, H> Send for CachedArr<A, P, H> where
A: Send + Sync,
H: Send + Sync,
P: Send,
A: Send + Sync,
H: Send + Sync,
P: Send,
impl<A, P, H> Sync for CachedArr<A, P, H> where
A: Send + Sync,
H: Send + Sync,
P: Sync,
A: Send + Sync,
H: Send + Sync,
P: Sync,
impl<A, P, H> Unpin for CachedArr<A, P, H> where
A: Unpin,
H: Unpin,
P: Unpin,
A: Unpin,
H: Unpin,
P: Unpin,
impl<A, P, H> UnwindSafe for CachedArr<A, P, H> where
A: RefUnwindSafe + UnwindSafe,
H: RefUnwindSafe + UnwindSafe,
P: UnwindSafe,
A: RefUnwindSafe + UnwindSafe,
H: RefUnwindSafe + UnwindSafe,
P: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> CallHasher for T where
T: Hash,
[src]
T: Hash,
impl<T> Erasable for T
[src]
unsafe fn unerase(this: NonNull<Erased>) -> NonNull<T>
[src]
const ACK_1_1_0: bool
[src]
fn erase(this: NonNull<Self>) -> NonNull<Erased>
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,