pub struct Tree { /* private fields */ }Expand description
A Lux install tree that supports multiple versions of the same dependency,
with packages addressed by their LockedPackageId
Implementations§
Source§impl Tree
impl Tree
pub fn as_rock_list(&self) -> Result<Vec<LockedPackage>, TreeError>
Source§impl Tree
impl Tree
pub fn match_rocks_and<F>( &self, req: &PackageReq, filter: F, ) -> Result<RockMatches, TreeError>
Trait Implementations§
Source§impl InstallTree for Tree
impl InstallTree for Tree
Source§fn version(&self) -> &LuaVersion
fn version(&self) -> &LuaVersion
The Lua version for which to install packages.
Source§fn prepare(&self, package: &LockedPackageSpec) -> Result<(), TreeError>
fn prepare(&self, package: &LockedPackageSpec) -> Result<(), TreeError>
Create the standard directories (src, lib, etc.) for a package.
Source§fn finalize(
&self,
package: &LockedPackage,
entry_type: EntryType,
) -> Result<(), TreeError>
fn finalize( &self, package: &LockedPackage, entry_type: EntryType, ) -> Result<(), TreeError>
Apply the custom layout once a package has been fully installed. Read more
Source§fn cleanup(
&self,
package: &LockedPackage,
entry_type: EntryType,
) -> Result<(), TreeError>
fn cleanup( &self, package: &LockedPackage, entry_type: EntryType, ) -> Result<(), TreeError>
Remove the install layout directories. Read more
Source§fn lockfile_path(&self) -> PathBuf
fn lockfile_path(&self) -> PathBuf
Get this tree’s lockfile path.
Source§fn layout_for(&self, package: &LockedPackageSpec) -> RockLayout
fn layout_for(&self, package: &LockedPackageSpec) -> RockLayout
The standard install layout for a package.
Source§fn unwrapped_bin(&self) -> PathBuf
fn unwrapped_bin(&self) -> PathBuf
Where unwrapped package binaries are installed
Source§fn test_tree(&self, config: &Config) -> Result<Self, TreeError>
fn test_tree(&self, config: &Config) -> Result<Self, TreeError>
The tree in which to install test dependencies.
Source§fn build_tree(&self, config: &Config) -> Result<Self, TreeError>
fn build_tree(&self, config: &Config) -> Result<Self, TreeError>
The tree in which to install build dependencies.
Source§fn list(&self) -> Result<HashMap<PackageName, Vec<LockedPackage>>, TreeError>
fn list(&self) -> Result<HashMap<PackageName, Vec<LockedPackage>>, TreeError>
List the packages that are installed in this tree.
Source§fn match_rocks(&self, req: &PackageReq) -> Result<RockMatches, TreeError>
fn match_rocks(&self, req: &PackageReq) -> Result<RockMatches, TreeError>
Find installed rocks that match the given
PackageReq.Auto Trait Implementations§
impl !RefUnwindSafe for Tree
impl !UnwindSafe for Tree
impl Freeze for Tree
impl Send for Tree
impl Sync for Tree
impl Unpin for Tree
impl UnsafeUnpin for Tree
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreimpl<T> OrderedSeq<'_, T> for Twhere
T: Clone,
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<'p, T> Seq<'p, T> for Twhere
T: Clone,
impl<'p, T> Seq<'p, T> for Twhere
T: Clone,
Source§impl<T, S> SpanWrap<S> for Twhere
S: WrappingSpan<T>,
impl<T, S> SpanWrap<S> for Twhere
S: WrappingSpan<T>,
Source§fn with_span(self, span: S) -> <S as WrappingSpan<Self>>::Spanned
fn with_span(self, span: S) -> <S as WrappingSpan<Self>>::Spanned
Invokes
WrappingSpan::make_wrapped to wrap an AST node in a span.