[][src]Struct pyo3_pack::PathWriter

pub struct PathWriter { /* fields omitted */ }

A ModuleWriter that adds the module somewhere in the filesystem, e.g. in a virtualenv

Methods

impl PathWriter[src]

pub fn venv(target: &Target, venv_dir: &Path) -> Result<Self, Error>[src]

Creates a ModuleWriter that adds the modul to the current virtualenv

pub fn from_path(path: impl AsRef<Path>) -> Self[src]

Writes the module to the given path

pub fn delete_dir(&self, relative: impl AsRef<Path>) -> Result<(), Error>[src]

Removes a directory relative to the base path if it exists.

This is to clean up the contents of an older develop call

Trait Implementations

impl ModuleWriter for PathWriter[src]

fn add_bytes(
    &mut self,
    target: impl AsRef<Path>,
    bytes: &[u8]
) -> Result<(), Error>
[src]

Adds a file with bytes as content in target relative to the module base path

fn add_file(
    &mut self,
    target: impl AsRef<Path>,
    source: impl AsRef<Path>
) -> Result<(), Error>
[src]

Copies the source file the the target path relative to the module base path

Auto Trait Implementations

impl Send for PathWriter

impl Sync for PathWriter

Blanket Implementations

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

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

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> BorrowMut<T> for T where
    T: ?Sized
[src]

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Erased for T

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

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