pub struct FixedSetProviderRef<'a> { /* private fields */ }Expand description
decleration provider with fixed set of decleration files.
this provider is same as FixedSetProvider, but it take references to the declaration files, not owning them. so it can redirect declarations from other provider.
§example
let provider = FixedSetProviderRef::new(&[
some_provider.load("file1").unwrap(),
other_provider.load("file2").unwrap(),
]);
provider.load("file2"); // => Some(DeclFile { name: "file2" })
provider.load("doesnt exist"); // => ImportError::NotFoundImplementations§
Trait Implementations§
Source§impl<'a> Clone for FixedSetProviderRef<'a>
impl<'a> Clone for FixedSetProviderRef<'a>
Source§fn clone(&self) -> FixedSetProviderRef<'a>
fn clone(&self) -> FixedSetProviderRef<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'a> Debug for FixedSetProviderRef<'a>
impl<'a> Debug for FixedSetProviderRef<'a>
Auto Trait Implementations§
impl<'a> Freeze for FixedSetProviderRef<'a>
impl<'a> RefUnwindSafe for FixedSetProviderRef<'a>
impl<'a> Send for FixedSetProviderRef<'a>
impl<'a> Sync for FixedSetProviderRef<'a>
impl<'a> Unpin for FixedSetProviderRef<'a>
impl<'a> UnwindSafe for FixedSetProviderRef<'a>
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