Struct jcm::UnitStatusList
source · #[repr(C)]pub struct UnitStatusList(pub Vec<UnitStatus>);Expand description
Convenience container for a list of UnitStatus items.
Tuple Fields§
§0: Vec<UnitStatus>Implementations§
source§impl UnitStatusList
impl UnitStatusList
sourcepub const fn new() -> Self
pub const fn new() -> Self
Creates a new UnitStatusList.
sourcepub fn items(&self) -> &[UnitStatus]
pub fn items(&self) -> &[UnitStatus]
Gets a reference to the list of UnitStatus items.
sourcepub fn into_inner(self) -> Vec<UnitStatus>
pub fn into_inner(self) -> Vec<UnitStatus>
Converts the UnitStatusList into its inner representation.
sourcepub fn to_bytes(&self, buf: &mut [u8]) -> Result<()>
pub fn to_bytes(&self, buf: &mut [u8]) -> Result<()>
Writes the UnitStatusList to a byte buffer.
sourcepub fn as_bytes(&self) -> Vec<u8>
pub fn as_bytes(&self) -> Vec<u8>
Converts the UnitStatusList into a byte vector.
sourcepub fn into_bytes(self) -> Vec<u8>
pub fn into_bytes(self) -> Vec<u8>
Converts the UnitStatusList into a byte vector.
sourcepub fn len(&self) -> usize
pub fn len(&self) -> usize
Gets the byte length of the UnitStatusList.
sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Gets whether the UnitStatusList is empty.
Trait Implementations§
source§impl Clone for UnitStatusList
impl Clone for UnitStatusList
source§fn clone(&self) -> UnitStatusList
fn clone(&self) -> UnitStatusList
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for UnitStatusList
impl Debug for UnitStatusList
source§impl Default for UnitStatusList
impl Default for UnitStatusList
source§impl Display for UnitStatusList
impl Display for UnitStatusList
source§impl PartialEq for UnitStatusList
impl PartialEq for UnitStatusList
source§fn eq(&self, other: &UnitStatusList) -> bool
fn eq(&self, other: &UnitStatusList) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl TryFrom<&[u8]> for UnitStatusList
impl TryFrom<&[u8]> for UnitStatusList
impl Eq for UnitStatusList
impl StructuralPartialEq for UnitStatusList
Auto Trait Implementations§
impl Freeze for UnitStatusList
impl RefUnwindSafe for UnitStatusList
impl Send for UnitStatusList
impl Sync for UnitStatusList
impl Unpin for UnitStatusList
impl UnwindSafe for UnitStatusList
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