pub trait UpdateShell {
// Required methods
fn add_faces<T>(
&self,
faces: impl IntoIterator<Item = T>,
core: &mut Core,
) -> Self
where T: Insert<Inserted = Handle<Face>>;
fn update_face<T, R>(
&self,
handle: &Handle<Face>,
update: impl FnOnce(&Handle<Face>, &mut Core) -> R,
core: &mut Core,
) -> Self
where T: Insert<Inserted = Handle<Face>>,
R: IntoIterator<Item = T>;
fn remove_face(&self, handle: &Handle<Face>) -> Self;
}
Expand description
Update a Shell
Required Methods§
Sourcefn add_faces<T>(
&self,
faces: impl IntoIterator<Item = T>,
core: &mut Core,
) -> Self
fn add_faces<T>( &self, faces: impl IntoIterator<Item = T>, core: &mut Core, ) -> Self
Add faces to the shell
Sourcefn update_face<T, R>(
&self,
handle: &Handle<Face>,
update: impl FnOnce(&Handle<Face>, &mut Core) -> R,
core: &mut Core,
) -> Self
fn update_face<T, R>( &self, handle: &Handle<Face>, update: impl FnOnce(&Handle<Face>, &mut Core) -> R, core: &mut Core, ) -> Self
Update a face of the shell
§Panics
Panics, if the object can’t be found.
Panics, if the update results in multiple handles referencing the same object.
Sourcefn remove_face(&self, handle: &Handle<Face>) -> Self
fn remove_face(&self, handle: &Handle<Face>) -> Self
Remove a face from the shell
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.