Struct pyoxidizerlib::environment::Environment[][src]

pub struct Environment {
    pub pyoxidizer_source: PyOxidizerSource,
    // some fields omitted
}

Describes the PyOxidizer run-time environment.

Fields

pyoxidizer_source: PyOxidizerSource

Where a copy of PyOxidizer can be obtained from.

Implementations

impl Environment[src]

pub fn new() -> Result<Self>[src]

Obtain a new instance.

pub fn cache_dir(&self) -> &Path[src]

Cache directory for PyOxidizer to use.

The cache is per-user but multi-process.

pub fn python_distributions_dir(&self) -> PathBuf[src]

Directory to use for storing Python distributions.

pub fn rust_dir(&self) -> PathBuf[src]

Directory to hold Rust toolchains.

pub fn unmanage_rust(&mut self) -> Result<()>[src]

Do not use a managed Rust.

When called, [self.ensure_rust_toolchain()] will attempt to locate a Rust install on the system rather than manage it itself.

pub fn find_executable(&self, name: &str) -> Result<Option<PathBuf>>[src]

Find an executable of the given name.

Resolves to Some(T) if an executable was found or None if not.

Errors if there were problems searching for executables.

pub fn ensure_rust_toolchain(
    &self,
    logger: &Logger,
    target_triple: Option<&str>
) -> Result<RustEnvironment>
[src]

Ensure a Rust toolchain suitable for building is available.

Trait Implementations

impl Clone for Environment[src]

impl Debug for Environment[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Err = <U as TryFrom<T>>::Err

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,