pub struct PropertyMap { /* private fields */ }Expand description
Sorted (key, value) entries with capacity fitted to
[reserved_slot_count].
Implementations§
Source§impl PropertyMap
impl PropertyMap
pub fn new() -> Self
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Sourcepub fn slot_capacity(&self) -> usize
pub fn slot_capacity(&self) -> usize
Buffer slots actually reserved. Empty maps reserve nothing.
pub fn get(&self, key: &str) -> Option<&Value>
pub fn contains_key(&self, key: &str) -> bool
pub fn iter(&self) -> impl Iterator<Item = (&String, &Value)>
pub fn keys(&self) -> impl Iterator<Item = &String>
pub fn values_mut(&mut self) -> impl Iterator<Item = &mut Value>
pub fn insert(&mut self, key: String, value: Value) -> Option<Value>
pub fn remove(&mut self, key: &str) -> Option<Value>
Source§impl PropertyMap
Arc is a fundamental type, so From<BTreeMap> for Arc<PropertyMap>
is an orphan impl. Callers wrap with PropertyMap::share.
impl PropertyMap
Arc is a fundamental type, so From<BTreeMap> for Arc<PropertyMap>
is an orphan impl. Callers wrap with PropertyMap::share.
Trait Implementations§
Source§impl Clone for PropertyMap
impl Clone for PropertyMap
Source§impl Debug for PropertyMap
impl Debug for PropertyMap
Source§impl Default for PropertyMap
impl Default for PropertyMap
Source§impl<'de> Deserialize<'de> for PropertyMap
impl<'de> Deserialize<'de> for PropertyMap
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<PropertyMap> for BTreeMap<String, Value>
impl From<PropertyMap> for BTreeMap<String, Value>
Source§fn from(map: PropertyMap) -> Self
fn from(map: PropertyMap) -> Self
Converts to this type from the input type.
Source§impl Index<&str> for PropertyMap
impl Index<&str> for PropertyMap
Source§impl<'a> IntoIterator for &'a PropertyMap
impl<'a> IntoIterator for &'a PropertyMap
Source§impl PartialEq for PropertyMap
impl PartialEq for PropertyMap
Source§impl Serialize for PropertyMap
impl Serialize for PropertyMap
impl StructuralPartialEq for PropertyMap
Auto Trait Implementations§
impl Forget for PropertyMap
impl Freeze for PropertyMap
impl Move for PropertyMap
impl RefUnwindSafe for PropertyMap
impl Send for PropertyMap
impl Sync for PropertyMap
impl Unpin for PropertyMap
impl UnsafeUnpin for PropertyMap
impl UnwindSafe for PropertyMap
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