Enum maturin::BridgeModel
source · pub enum BridgeModel {
Bin(Option<(String, usize)>),
Bindings(String, usize),
BindingsAbi3(u8, u8),
Cffi,
UniFfi,
}
Expand description
The way the rust code is used in the wheel
Variants§
Bin(Option<(String, usize)>)
A rust binary to be shipped a python package The String is the name of the bindings providing crate, e.g. pyo3, the number is the minimum minor python version
Bindings(String, usize)
A native module with pyo3 or rust-cpython bindings. The String is the name of the bindings providing crate, e.g. pyo3, the number is the minimum minor python version
BindingsAbi3(u8, u8)
Bindings
, but specifically for pyo3 with feature flags that allow building a single wheel
for all cpython versions (pypy & graalpy still need multiple versions).
The numbers are the minimum major and minor version
Cffi
A native module with c bindings, i.e. #[no_mangle] extern "C" <some item>
UniFfi
A native module generated from uniffi
Implementations§
source§impl BridgeModel
impl BridgeModel
sourcepub fn unwrap_bindings(&self) -> &str
pub fn unwrap_bindings(&self) -> &str
Returns the name of the bindings crate
sourcepub fn is_bindings(&self, name: &str) -> bool
pub fn is_bindings(&self, name: &str) -> bool
Test whether this is using a specific bindings crate
Trait Implementations§
source§impl Clone for BridgeModel
impl Clone for BridgeModel
source§fn clone(&self) -> BridgeModel
fn clone(&self) -> BridgeModel
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for BridgeModel
impl Debug for BridgeModel
source§impl Display for BridgeModel
impl Display for BridgeModel
source§impl PartialEq for BridgeModel
impl PartialEq for BridgeModel
source§fn eq(&self, other: &BridgeModel) -> bool
fn eq(&self, other: &BridgeModel) -> bool
self
and other
values to be equal, and is used
by ==
.impl Eq for BridgeModel
impl StructuralPartialEq for BridgeModel
Auto Trait Implementations§
impl Freeze for BridgeModel
impl RefUnwindSafe for BridgeModel
impl Send for BridgeModel
impl Sync for BridgeModel
impl Unpin for BridgeModel
impl UnwindSafe for BridgeModel
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
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.