SortedInsertArcMutexBy

Trait SortedInsertArcMutexBy 

Source
pub trait SortedInsertArcMutexBy<T>: SortedInsertArcMutexBasic<T> {
    // Provided method
    fn sorted_insert_by<F: FnMut(&Arc<Mutex<T>>, &T) -> bool>(
        &mut self,
        element: Arc<Mutex<T>>,
        f: F,
    ) -> usize { ... }
}

Provided Methods§

Source

fn sorted_insert_by<F: FnMut(&Arc<Mutex<T>>, &T) -> bool>( &mut self, element: Arc<Mutex<T>>, f: F, ) -> usize

Insert elements to this sorted collection by a specific comparator and return the inserted index. Use linear search to find the index where a matching element could be inserted.

§Safety

This function will panic if the element is locked.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<T> SortedInsertArcMutexBy<T> for VecDeque<Arc<Mutex<T>>>

Source§

impl<T> SortedInsertArcMutexBy<T> for Vec<Arc<Mutex<T>>>

Implementors§