pub struct MeshCache { /* private fields */ }Implementations§
Source§impl MeshCache
impl MeshCache
pub fn new() -> MeshCache
pub fn insert(&mut self, mesh: Mesh) -> Result<MeshId, MeshError>
pub fn get(&self, id: MeshId) -> Option<&Mesh>
pub fn bounds(&self, id: MeshId) -> Option<Bounds>
Sourcepub fn update(&mut self, id: MeshId, mesh: Mesh) -> Result<bool, MeshError>
pub fn update(&mut self, id: MeshId, mesh: Mesh) -> Result<bool, MeshError>
Replaces geometry in-place after complete validation. Old data survives a bad update.
pub fn remove(&mut self, id: MeshId) -> Option<Mesh>
pub fn stats(&self) -> CacheStats
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MeshCache
impl RefUnwindSafe for MeshCache
impl Send for MeshCache
impl Sync for MeshCache
impl Unpin for MeshCache
impl UnwindSafe for MeshCache
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more