Enum splay_tree::map::Entry [] [src]

pub enum Entry<'a, K: 'a, V: 'a> {
    Occupied(OccupiedEntry<'a, K, V>),
    Vacant(VacantEntry<'a, K, V>),
}

A view into a single entry in a map, which may either be vacant or occupied.

Variants

An occupied entry

A vacant entry

Methods

impl<'a, K: 'a, V: 'a> Entry<'a, K, V> where
    K: Ord
[src]

[src]

Returns a reference to this entry's key.

[src]

Ensures a value is in the entry by inserting the default if empty, and returns a mutable reference to the value in the entry.

[src]

Ensures a value is in the entry by inserting the result of the default function if empty, and returns a mutable reference to the value in the entry.

Trait Implementations

Auto Trait Implementations

impl<'a, K, V> Send for Entry<'a, K, V> where
    K: Send,
    V: Send

impl<'a, K, V> Sync for Entry<'a, K, V> where
    K: Sync,
    V: Sync