pub struct SassMap(/* private fields */);Implementations§
Source§impl SassMap
impl SassMap
pub const fn new() -> SassMap
pub const fn new_with(elements: Vec<(Spanned<Value>, Value)>) -> SassMap
pub fn get(self, key: &Value) -> Option<Value>
pub fn get_ref(&self, key: &Value) -> Option<&Value>
pub fn remove(&mut self, key: &Value)
pub fn merge(&mut self, other: SassMap)
pub fn iter(&self) -> Iter<'_, (Spanned<Value>, Value)>
pub fn keys(self) -> Vec<Value>
pub fn values(self) -> Vec<Value>
pub fn contains(&self, key: &Value) -> bool
pub fn as_list(self) -> Vec<Value>
Sourcepub fn insert(&mut self, key: Spanned<Value>, value: Value) -> bool
pub fn insert(&mut self, key: Spanned<Value>, value: Value) -> bool
Returns true if the key already exists
pub fn is_empty(&self) -> bool
Trait Implementations§
Source§impl IntoIterator for SassMap
impl IntoIterator for SassMap
impl Eq for SassMap
Auto Trait Implementations§
impl Freeze for SassMap
impl !RefUnwindSafe for SassMap
impl !Send for SassMap
impl !Sync for SassMap
impl Unpin for SassMap
impl !UnwindSafe for SassMap
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§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.