pub struct QVector { /* private fields */ }
Implementations§
source§impl QVector
impl QVector
sourcepub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> bool
Check if the vector is empty.
§Examples
use qwt::QVector;
let qv = QVector::default();
assert!(qv.is_empty());
Trait Implementations§
source§impl AccessQuad for QVector
impl AccessQuad for QVector
source§unsafe fn get_unchecked(&self, i: usize) -> u8
unsafe fn get_unchecked(&self, i: usize) -> u8
source§fn get(&self, i: usize) -> Option<u8>
fn get(&self, i: usize) -> Option<u8>
Access the i
th value in the quaternary vector
or None
if i
is out of bounds.
§Examples
use qwt::QVector;
use qwt::AccessQuad;
let qv: QVector = [0, 1, 2, 3].into_iter().cycle().take(10).collect();
assert_eq!(qv.get(8), Some(0));
assert_eq!(qv.get(10), None);
source§impl<'de> Deserialize<'de> for QVector
impl<'de> Deserialize<'de> for QVector
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<T> FromIterator<T> for QVector
impl<T> FromIterator<T> for QVector
source§fn from_iter<I>(iter: I) -> Selfwhere
I: IntoIterator<Item = T>,
fn from_iter<I>(iter: I) -> Selfwhere
I: IntoIterator<Item = T>,
Creates a value from an iterator. Read more
source§impl<'a> IntoIterator for &'a QVector
impl<'a> IntoIterator for &'a QVector
source§impl IntoIterator for QVector
impl IntoIterator for QVector
source§impl PartialEq for QVector
impl PartialEq for QVector
source§impl SpaceUsage for QVector
impl SpaceUsage for QVector
source§fn space_usage_byte(&self) -> usize
fn space_usage_byte(&self) -> usize
Gives the space usage of the data structure in bytes.
source§fn space_usage_KiB(&self) -> f64
fn space_usage_KiB(&self) -> f64
Gives the space usage of the data structure in KiB.
source§fn space_usage_MiB(&self) -> f64
fn space_usage_MiB(&self) -> f64
Gives the space usage of the data structure in MiB.
source§fn space_usage_GiB(&self) -> f64
fn space_usage_GiB(&self) -> f64
Gives the space usage of the data structure in GiB.
impl Eq for QVector
impl StructuralPartialEq for QVector
Auto Trait Implementations§
impl Freeze for QVector
impl RefUnwindSafe for QVector
impl Send for QVector
impl Sync for QVector
impl Unpin for QVector
impl UnwindSafe for QVector
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)