Struct rkyv::niche::option_nonzero::ArchivedOptionNonZeroU8
source · [−]#[repr(transparent)]pub struct ArchivedOptionNonZeroU8 { /* private fields */ }
Expand description
A niched archived Option<NonZeroU8>
Implementations
sourceimpl ArchivedOptionNonZeroU8
impl ArchivedOptionNonZeroU8
sourcepub fn as_ref(&self) -> Option<&Archived<NonZeroU8>>
pub fn as_ref(&self) -> Option<&Archived<NonZeroU8>>
Converts to an Option<&Archived<NonZeroU8>>
sourcepub fn as_mut(&mut self) -> Option<&mut Archived<NonZeroU8>>
pub fn as_mut(&mut self) -> Option<&mut Archived<NonZeroU8>>
Converts to an Option<&mut Archived<NonZeroU8>>
sourcepub fn as_pin_ref(self: Pin<&Self>) -> Option<Pin<&Archived<NonZeroU8>>>
pub fn as_pin_ref(self: Pin<&Self>) -> Option<Pin<&Archived<NonZeroU8>>>
Converts from Pin<&ArchivedOptionNonZeroU8>
to Option<Pin<&Archived<NonZeroU8>>>
.
sourcepub fn as_pin_mut(self: Pin<&mut Self>) -> Option<Pin<&mut Archived<NonZeroU8>>>
pub fn as_pin_mut(self: Pin<&mut Self>) -> Option<Pin<&mut Archived<NonZeroU8>>>
Converts from Pin<&mut ArchivedOptionNonZeroU8>
to Option<Pin<&mut Archived<NonZeroU8>>>
.
sourcepub fn iter(&self) -> Iter<'_, Archived<NonZeroU8>>
pub fn iter(&self) -> Iter<'_, Archived<NonZeroU8>>
Returns an iterator over the possibly contained value.
sourcepub fn iter_mut(&mut self) -> IterMut<'_, Archived<NonZeroU8>>
pub fn iter_mut(&mut self) -> IterMut<'_, Archived<NonZeroU8>>
Returns a mutable iterator over the possibly contained value.
sourcepub fn get_or_insert(&mut self, v: NonZeroU8) -> &mut Archived<NonZeroU8>
pub fn get_or_insert(&mut self, v: NonZeroU8) -> &mut Archived<NonZeroU8>
Inserts v
into the option if it is None
, then returns a mutable
reference to the contained value.
Trait Implementations
sourceimpl Debug for ArchivedOptionNonZeroU8
impl Debug for ArchivedOptionNonZeroU8
sourceimpl<D: Fallible + ?Sized> DeserializeWith<ArchivedOptionNonZeroU8, Option<NonZeroU8>, D> for Niche
impl<D: Fallible + ?Sized> DeserializeWith<ArchivedOptionNonZeroU8, Option<NonZeroU8>, D> for Niche
sourcefn deserialize_with(
field: &ArchivedOptionNonZeroU8,
_: &mut D
) -> Result<Option<NonZeroU8>, D::Error>
fn deserialize_with(
field: &ArchivedOptionNonZeroU8,
_: &mut D
) -> Result<Option<NonZeroU8>, D::Error>
Deserializes the field type F
using the given deserializer.
sourceimpl Hash for ArchivedOptionNonZeroU8
impl Hash for ArchivedOptionNonZeroU8
sourceimpl Ord for ArchivedOptionNonZeroU8
impl Ord for ArchivedOptionNonZeroU8
sourceimpl PartialOrd<ArchivedOptionNonZeroU8> for ArchivedOptionNonZeroU8
impl PartialOrd<ArchivedOptionNonZeroU8> for ArchivedOptionNonZeroU8
sourcefn partial_cmp(&self, other: &Self) -> Option<Ordering>
fn partial_cmp(&self, other: &Self) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Eq for ArchivedOptionNonZeroU8
Auto Trait Implementations
impl RefUnwindSafe for ArchivedOptionNonZeroU8
impl Send for ArchivedOptionNonZeroU8
impl Sync for ArchivedOptionNonZeroU8
impl Unpin for ArchivedOptionNonZeroU8
impl UnwindSafe for ArchivedOptionNonZeroU8
Blanket Implementations
sourceimpl<T> ArchivePointee for T
impl<T> ArchivePointee for T
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
sourcefn pointer_metadata(_: &Self::ArchivedMetadata) -> <Self as Pointee>::Metadata
fn pointer_metadata(_: &Self::ArchivedMetadata) -> <Self as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more