Skip to main content

ClearContainer

Trait ClearContainer 

Source
pub trait ClearContainer {
    // Required method
    fn clear(&mut self);
}
Expand description

A trait for containers that can be cleared.

Required Methods§

Source

fn clear(&mut self)

Clear the contents of the container.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T> ClearContainer for Vec<T>

Source§

fn clear(&mut self)

Implementors§