pub trait Clearable {
// Required method
fn clear_for_reuse(&mut self);
}Expand description
A clearable trait for objects that can be reset for reuse.
Required Methods§
Sourcefn clear_for_reuse(&mut self)
fn clear_for_reuse(&mut self)
Clears the object’s contents while preserving capacity.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".