pub struct PatchedMap {
pub patches: HashMap<String, Arc<dyn Fn(&mut PatchedMap, &mut Token) + Send + Sync>>,
/* private fields */
}Fields§
§patches: HashMap<String, Arc<dyn Fn(&mut PatchedMap, &mut Token) + Send + Sync>>Implementations§
Source§impl PatchedMap
impl PatchedMap
pub fn new() -> Self
pub fn with_capacity(capacity: usize) -> Self
pub fn push_back<T: Into<Token>>(&mut self, key_str: &str, value: T) -> bool
pub fn update<T: Into<Token>>( &mut self, key: &str, value: T, ) -> Result<(), String>
pub fn contains(&self, key: &str) -> bool
pub fn keys(&self) -> Keys<'_, String, Token>
pub fn iter(&self) -> SeqIter<'_> ⓘ
Trait Implementations§
Source§impl Clone for PatchedMap
impl Clone for PatchedMap
Source§fn clone(&self) -> PatchedMap
fn clone(&self) -> PatchedMap
Returns a duplicate 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 PatchedMap
impl Debug for PatchedMap
Source§impl Default for PatchedMap
impl Default for PatchedMap
Source§fn default() -> PatchedMap
fn default() -> PatchedMap
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PatchedMap
impl<'de> Deserialize<'de> for PatchedMap
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 From<PatchedMap> for Token
impl From<PatchedMap> for Token
Source§fn from(map: PatchedMap) -> Self
fn from(map: PatchedMap) -> Self
Converts to this type from the input type.
Source§impl Index<&str> for PatchedMap
impl Index<&str> for PatchedMap
Source§impl IndexMut<&str> for PatchedMap
impl IndexMut<&str> for PatchedMap
Auto Trait Implementations§
impl Freeze for PatchedMap
impl !RefUnwindSafe for PatchedMap
impl Send for PatchedMap
impl Sync for PatchedMap
impl Unpin for PatchedMap
impl !UnwindSafe for PatchedMap
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