pub fn or_insert_with<F>(self, default: F) -> &'a mut V
    where
        F: FnOnce() -> V,
    {
        self.or_insert_with_key(|_| default())
    }
/// Ensures a value is present in the entry by inserting the result of the default function
/// if not, and returns a mutable reference to the value.
///
/// # Examples
///
/// ```
/// use bptree::BpTreeMap;
///
/// let mut map = BpTreeMap::new();
/// map.entry(1).or_insert_with(|| "One".to_string());
/// assert_eq!(&*map[&1], "One");
/// ```
Ensures a value is present in the entry by inserting the result of the default function
if not, and returns a mutable reference to the value.
Ensures a value is present in the entry by inserting the result of the default function if not and returns a mutable reference to the value .
pub fn or_insert_with<F>(self, default: F) -> &'a mut V
    where
        F: FnOnce() -> V,
    {
        self.or_insert_with_key(|_| default())
    }
pub fn or_insert_with < F > ( self , default : F ) -> & ' a mut V where F : FnOnce ( ) -> V , { self . or_insert_with_key ( | _ | default ( ) ) }
Ensures a value is present in the entry by inserting the result of the default function
if not, and returns a mutable reference to the value.
Ensures a value is present in the entry by inserting the result of the default function if not and returns a mutable reference to the value .
self
default
F
self
default
F
examples
```
use bptree::BpTreeMap.


` ` ` use bptree :: BpTreeMap .