Struct rkyv::collections::btree_map::ArchivedBTreeMap [−][src]
pub struct ArchivedBTreeMap<K, V> { /* fields omitted */ }
Expand description
An archived BTreeMap
.
Implementations
Returns true
if the map contains a value for the specified key.
The key may be any borrowed form of the map’s key type, but the ordering on the borrowed form must match the ordering on the key type.
Returns a reference to the value corresponding to the key.
The key may be any borrowed form of the map’s key type, but the ordering on the borrowed form must match the ordering on the key type.
Returns the key-value pair corresponding to the supplied key.
The supplied key may be any borrowed form of the map’s key type, but the ordering on the borrowed form must match the ordering on the key type.
Gets an iterator over the entries of the map, sorted by key.
Gets an iterator over the keys of the map, in sorted order.
Gets an iterator over the values of the map, in order by key.
pub unsafe fn resolve_from_len(
len: usize,
pos: usize,
resolver: BTreeMapResolver,
out: *mut Self
)
pub unsafe fn resolve_from_len(
len: usize,
pos: usize,
resolver: BTreeMapResolver,
out: *mut Self
)
Resolves a B-tree map from its length.
Safety
len
must be the number of elements that were serializedpos
must be the position ofout
within the archiveresolver
must be the result of serializing a B-tree map
Trait Implementations
impl<K, V, C: ?Sized> CheckBytes<C> for ArchivedBTreeMap<K, V> where
K: CheckBytes<C> + Ord,
V: CheckBytes<C>,
C: ArchiveContext,
C::Error: Error,
impl<K, V, C: ?Sized> CheckBytes<C> for ArchivedBTreeMap<K, V> where
K: CheckBytes<C> + Ord,
V: CheckBytes<C>,
C: ArchiveContext,
C::Error: Error,
type Error = ArchivedBTreeMapError<K::Error, V::Error, C::Error>
type Error = ArchivedBTreeMapError<K::Error, V::Error, C::Error>
The error that may result from checking the type.
unsafe fn check_bytes<'a>(
value: *const Self,
context: &mut C
) -> Result<&'a Self, Self::Error>
unsafe fn check_bytes<'a>(
value: *const Self,
context: &mut C
) -> Result<&'a Self, Self::Error>
Checks whether the given pointer points to a valid value within the given context. Read more
impl<K: Archive + Ord, V: Archive, D: Fallible + ?Sized> Deserialize<BTreeMap<K, V>, D> for ArchivedBTreeMap<K::Archived, V::Archived> where
K::Archived: Deserialize<K, D> + Ord,
V::Archived: Deserialize<V, D>,
impl<K: Archive + Ord, V: Archive, D: Fallible + ?Sized> Deserialize<BTreeMap<K, V>, D> for ArchivedBTreeMap<K::Archived, V::Archived> where
K::Archived: Deserialize<K, D> + Ord,
V::Archived: Deserialize<V, D>,
impl<K: PartialOrd, V: PartialOrd> PartialOrd<ArchivedBTreeMap<K, V>> for ArchivedBTreeMap<K, V>
impl<K: PartialOrd, V: PartialOrd> PartialOrd<ArchivedBTreeMap<K, V>> for ArchivedBTreeMap<K, V>
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
Auto Trait Implementations
impl<K, V> RefUnwindSafe for ArchivedBTreeMap<K, V> where
K: RefUnwindSafe,
V: RefUnwindSafe,
impl<K, V> Send for ArchivedBTreeMap<K, V> where
K: Send,
V: Send,
impl<K, V> Sync for ArchivedBTreeMap<K, V> where
K: Sync,
V: Sync,
impl<K, V> !Unpin for ArchivedBTreeMap<K, V>
impl<K, V> UnwindSafe for ArchivedBTreeMap<K, V> where
K: UnwindSafe,
V: UnwindSafe,
Blanket Implementations
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Converts some archived metadata to the pointer metadata for itself.
Mutably borrows from an owned value. Read more
impl<F, W, T, D> Deserialize<With<T, W>, D> for F where
D: Fallible + ?Sized,
F: ?Sized,
W: DeserializeWith<F, T, D>,
impl<F, W, T, D> Deserialize<With<T, W>, D> for F where
D: Fallible + ?Sized,
F: ?Sized,
W: DeserializeWith<F, T, D>,