pub struct Component<'a> { /* private fields */ }
Expand description
A component of an object identifier.
Although these components are integers, they are encoded in a slightly
inconvenient way. Because of this we don’t convert them to native integers
but rather keep them as references to the underlying octets.
This type allows comparison and formatting, which hopefully is all you’ll
need. If you insist, the method to_u32
allows you to try to convert a
component to a native integer.
Attempts to convert the component to u32
.
Since the component’s value can be larger than the maximum value of
a u32
, this may fail in which case the method will return None
.
Performs copy-assignment from
source
.
Read more
Formats the value using the given formatter.
Read more
This method tests for
self
and
other
values to be equal, and is used
by
==
.
Read more
This method tests for
!=
. The default implementation is almost always
sufficient, and should not be overridden without very good reason.
Read more
Immutably borrows from an owned value.
Read more
Mutably borrows from an owned value.
Read more
Returns the argument unchanged.
Calls U::from(self)
.
That is, this conversion is whatever the implementation of
From<T> for U
chooses to do.
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning.
Read more
Uses borrowed data to replace owned data, usually by cloning.
Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.