pub struct Resolver { /* private fields */ }Expand description
Import path resolver
Implementations§
Source§impl Resolver
impl Resolver
Sourcepub fn add_package_path<P: AsRef<Path>>(&mut self, path: P)
pub fn add_package_path<P: AsRef<Path>>(&mut self, path: P)
Add a package resolution path
Sourcepub fn resolve(&self, import_path: &str) -> Result<ResolvedImport, String>
pub fn resolve(&self, import_path: &str) -> Result<ResolvedImport, String>
Resolve an import path
Sourcepub fn set_base_dir<P: AsRef<Path>>(&mut self, base_dir: P)
pub fn set_base_dir<P: AsRef<Path>>(&mut self, base_dir: P)
Change the base directory
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Resolver
impl RefUnwindSafe for Resolver
impl Send for Resolver
impl Sync for Resolver
impl Unpin for Resolver
impl UnwindSafe for Resolver
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