Struct rkyv::collections::swiss_table::index_set::ArchivedIndexSet
source · pub struct ArchivedIndexSet<K, H = FxHasher64> { /* private fields */ }
Expand description
An archived IndexSet
.
Implementations§
source§impl<K, H> ArchivedIndexSet<K, H>
impl<K, H> ArchivedIndexSet<K, H>
source§impl<K, H: Default + Hasher> ArchivedIndexSet<K, H>
impl<K, H: Default + Hasher> ArchivedIndexSet<K, H>
sourcepub fn get_full<Q>(&self, k: &Q) -> Option<(usize, &K)>
pub fn get_full<Q>(&self, k: &Q) -> Option<(usize, &K)>
Returns the item index and value stored in the set, if any.
sourcepub fn get_index_of<Q>(&self, key: &Q) -> Option<usize>
pub fn get_index_of<Q>(&self, key: &Q) -> Option<usize>
Returns the index of a key if it exists in the set.
sourcepub unsafe fn resolve_from_len(
len: usize,
load_factor: (usize, usize),
pos: usize,
resolver: IndexSetResolver,
out: *mut Self
)
pub unsafe fn resolve_from_len( len: usize, load_factor: (usize, usize), pos: usize, resolver: IndexSetResolver, out: *mut Self )
Resolves an archived index map from a given length and parameters.
§Safety
out
must point to a Self
that properly aligned and valid for writes.
sourcepub fn serialize_from_iter<'a, I, UK, S>(
iter: I,
load_factor: (usize, usize),
serializer: &mut S
) -> Result<IndexSetResolver, S::Error>
pub fn serialize_from_iter<'a, I, UK, S>( iter: I, load_factor: (usize, usize), serializer: &mut S ) -> Result<IndexSetResolver, S::Error>
Serializes an iterator of keys as an index set.
Trait Implementations§
source§impl<K, H, __C: Fallible + ?Sized> CheckBytes<__C> for ArchivedIndexSet<K, H>
impl<K, H, __C: Fallible + ?Sized> CheckBytes<__C> for ArchivedIndexSet<K, H>
source§unsafe fn check_bytes(
value: *const Self,
context: &mut __C
) -> Result<(), <__C as Fallible>::Error>
unsafe fn check_bytes( value: *const Self, context: &mut __C ) -> Result<(), <__C as Fallible>::Error>
Checks whether the given pointer points to a valid value within the
given context. Read more
source§impl<K: Debug, H> Debug for ArchivedIndexSet<K, H>
impl<K: Debug, H> Debug for ArchivedIndexSet<K, H>
source§impl<K: PartialEq, H> PartialEq for ArchivedIndexSet<K, H>
impl<K: PartialEq, H> PartialEq for ArchivedIndexSet<K, H>
impl<K: Eq, H> Eq for ArchivedIndexSet<K, H>
impl<K, H> Portable for ArchivedIndexSet<K, H>
Auto Trait Implementations§
impl<K, H> Freeze for ArchivedIndexSet<K, H>
impl<K, H> RefUnwindSafe for ArchivedIndexSet<K, H>where
H: RefUnwindSafe,
K: RefUnwindSafe,
impl<K, H> Send for ArchivedIndexSet<K, H>
impl<K, H> Sync for ArchivedIndexSet<K, H>
impl<K, H = FxHasher64> !Unpin for ArchivedIndexSet<K, H>
impl<K, H> UnwindSafe for ArchivedIndexSet<K, H>where
H: UnwindSafe,
K: UnwindSafe,
Blanket Implementations§
source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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
source§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.