[][src]Enum pyoxidizerlib::py_packaging::fsscan::PythonFileResource

pub enum PythonFileResource {
    Source {
        package: String,
        stem: String,
        full_name: String,
        path: PathBuf,
    },
    Bytecode {
        package: String,
        stem: String,
        full_name: String,
        path: PathBuf,
    },
    BytecodeOpt1 {
        package: String,
        stem: String,
        full_name: String,
        path: PathBuf,
    },
    BytecodeOpt2 {
        package: String,
        stem: String,
        full_name: String,
        path: PathBuf,
    },
    ExtensionModule {
        package: String,
        stem: String,
        full_name: String,
        path: PathBuf,
    },
    Resource(FileBasedResource),
    EggFile {
        path: PathBuf,
    },
    PthFile {
        path: PathBuf,
    },
    Other {
        package: String,
        stem: String,
        full_name: String,
        path: PathBuf,
    },
}

Represents a Python resource backed by the filesystem.

Variants

Source

Fields of Source

package: String

Python package name of this resource.

For resources in the root, this will likely be the resource name.

For modules that are packages (e.g. __init__.py or __init__.pyc files, this will be the same as full_name.

For regular modules, this will be all but the final component in full_name.

stem: String

Final "stem" name of this resource.

This is derived from the file name's basename.

For resources that define packages, this is an empty string.

full_name: String

Full resource name of this resource.

This is typically how importlib refers to the resource.

e.g. foo.bar.

For resources that are packages, this is equivalent to package. For non-package resources, this is package.stem.

path: PathBuf

Filesystem path to this resource.

Bytecode

Fields of Bytecode

package: Stringstem: Stringfull_name: Stringpath: PathBuf
BytecodeOpt1

Fields of BytecodeOpt1

package: Stringstem: Stringfull_name: Stringpath: PathBuf
BytecodeOpt2

Fields of BytecodeOpt2

package: Stringstem: Stringfull_name: Stringpath: PathBuf
ExtensionModule

Fields of ExtensionModule

package: Stringstem: Stringfull_name: Stringpath: PathBuf
EggFile

Fields of EggFile

path: PathBuf
PthFile

Fields of PthFile

path: PathBuf
Other

Fields of Other

package: Stringstem: Stringfull_name: Stringpath: PathBuf

Trait Implementations

impl Debug for PythonFileResource[src]

impl PartialEq<PythonFileResource> for PythonFileResource[src]

impl StructuralPartialEq for PythonFileResource[src]

impl<'_> TryFrom<&'_ PythonFileResource> for PythonResource[src]

type Error = Error

The type returned in the event of a conversion error.

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, 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, 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>,