pub struct Designations;Expand description
The designations of one concept, packed in index order.
Each entry carries its designation index, so a gap in the indices the build wrote cannot shift a later designation into the wrong slot.
Implementations§
Source§impl Designations
impl Designations
Sourcepub fn encode(entries: &[(u32, &[u8])]) -> Vec<u8> ⓘ
pub fn encode(entries: &[(u32, &[u8])]) -> Vec<u8> ⓘ
The bytes of entries, each a designation index and its encoded record.
Sourcepub fn decode(bytes: &[u8]) -> Result<Vec<Designation>, RecordError>
pub fn decode(bytes: &[u8]) -> Result<Vec<Designation>, RecordError>
Every designation, in the order the build wrote them.
§Errors
Returns RecordError when the entries are truncated or a designation
is damaged.
Sourcepub fn at(bytes: &[u8], index: u32) -> Result<Option<Designation>, RecordError>
pub fn at(bytes: &[u8], index: u32) -> Result<Option<Designation>, RecordError>
The designation stored under index, if the concept has one.
§Errors
Returns RecordError when the entries are truncated or the
designation is damaged.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Designations
impl RefUnwindSafe for Designations
impl Send for Designations
impl Sync for Designations
impl Unpin for Designations
impl UnsafeUnpin for Designations
impl UnwindSafe for Designations
Blanket Implementations§
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