pub struct RegistrySet { /* private fields */ }Expand description
A named collection of Registry implementations.
Each registry is stored under a string identifier (e.g. "thunderstore",
"local") and can be looked up by name at runtime.
§Examples
use loadsmith_registry::{RegistrySet, LocalRegistry};
let mut set = RegistrySet::new();
assert!(set.get("local").is_none());
// Registries can be added and retrieved by name.
set.add("local", LocalRegistry::new());
assert!(set.get("local").is_some());Implementations§
Trait Implementations§
Source§impl Debug for RegistrySet
impl Debug for RegistrySet
Auto Trait Implementations§
impl !RefUnwindSafe for RegistrySet
impl !UnwindSafe for RegistrySet
impl Freeze for RegistrySet
impl Send for RegistrySet
impl Sync for RegistrySet
impl Unpin for RegistrySet
impl UnsafeUnpin for RegistrySet
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