Struct partiql_value::List
source · pub struct List(/* private fields */);
Expand description
Represents a PartiQL List value, e.g. [1, 2, ‘one’]
Implementations§
source§impl List
impl List
pub fn push(&mut self, value: Value)
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn get(&self, idx: i64) -> Option<&Value>
pub fn get_mut(&mut self, idx: i64) -> Option<&mut Value>
pub fn take_val(self, idx: i64) -> Option<Value>
pub fn iter(&self) -> ListIter<'_> ⓘ
pub fn reserve(&mut self, additional: usize)
pub fn to_vec(self) -> Vec<Value>
Trait Implementations§
source§impl Extend<Value> for List
impl Extend<Value> for List
source§fn extend<Iter: IntoIterator<Item = Value>>(&mut self, iter: Iter)
fn extend<Iter: IntoIterator<Item = Value>>(&mut self, iter: Iter)
Extends a collection with the contents of an iterator. Read more
source§fn extend_one(&mut self, item: A)
fn extend_one(&mut self, item: A)
🔬This is a nightly-only experimental API. (
extend_one
)Extends a collection with exactly one element.
source§fn extend_reserve(&mut self, additional: usize)
fn extend_reserve(&mut self, additional: usize)
🔬This is a nightly-only experimental API. (
extend_one
)Reserves capacity in a collection for the given number of additional elements. Read more
source§impl<'a> IntoIterator for &'a List
impl<'a> IntoIterator for &'a List
source§impl IntoIterator for List
impl IntoIterator for List
source§impl Ord for List
impl Ord for List
source§impl PartialEq<List> for List
impl PartialEq<List> for List
source§impl PartialOrd<List> for List
impl PartialOrd<List> for List
1.0.0 · source§fn 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 moreimpl Eq for List
impl StructuralEq for List
Auto Trait Implementations§
impl RefUnwindSafe for List
impl Send for List
impl Sync for List
impl Unpin for List
impl UnwindSafe for List
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