pub struct AliasRegistry { /* private fields */ }Expand description
Registry of model aliases
Implementations§
Source§impl AliasRegistry
impl AliasRegistry
Sourcepub fn with_defaults() -> Self
pub fn with_defaults() -> Self
Create registry with default aliases
Sourcepub fn add(&mut self, entry: AliasEntry)
pub fn add(&mut self, entry: AliasEntry)
Add an alias entry
Sourcepub fn get(&self, alias: &str) -> Option<&AliasEntry>
pub fn get(&self, alias: &str) -> Option<&AliasEntry>
Get an alias entry
Sourcepub fn list(&self) -> Vec<&AliasEntry>
pub fn list(&self) -> Vec<&AliasEntry>
Get all aliases
Sourcepub fn resolve(&self, reference: &str) -> ResolvedAlias
pub fn resolve(&self, reference: &str) -> ResolvedAlias
Resolve a model reference
Returns the full URI and optional quantization
Trait Implementations§
Source§impl Clone for AliasRegistry
impl Clone for AliasRegistry
Source§fn clone(&self) -> AliasRegistry
fn clone(&self) -> AliasRegistry
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AliasRegistry
impl Debug for AliasRegistry
Source§impl Default for AliasRegistry
impl Default for AliasRegistry
Source§fn default() -> AliasRegistry
fn default() -> AliasRegistry
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for AliasRegistry
impl RefUnwindSafe for AliasRegistry
impl Send for AliasRegistry
impl Sync for AliasRegistry
impl Unpin for AliasRegistry
impl UnsafeUnpin for AliasRegistry
impl UnwindSafe for AliasRegistry
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