[][src]Trait pyo3::conversion::IntoPy

pub trait IntoPy<T>: Sized {
    fn into_py(self, py: Python<'_>) -> T;
}

Similar to std::convert::Into, just that it requires a gil token.

Required methods

fn into_py(self, py: Python<'_>) -> T

Performs the conversion.

Loading content...

Implementations on Foreign Types

impl<T> IntoPy<PyObject> for Option<T> where
    T: IntoPy<PyObject>, 
[src]

impl<K, V, H> IntoPy<PyObject> for HashMap<K, V, H> where
    K: Hash + Eq + IntoPy<PyObject>,
    V: IntoPy<PyObject>,
    H: BuildHasher
[src]

impl<K, V> IntoPy<PyObject> for BTreeMap<K, V> where
    K: Eq + IntoPy<PyObject>,
    V: IntoPy<PyObject>, 
[src]

impl<T> IntoPy<PyObject> for [T; 0] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 1] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 2] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 3] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 4] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 5] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 6] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 7] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 8] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 9] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 10] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 11] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 12] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 13] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 14] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 15] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 16] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 17] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 18] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 19] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 20] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 21] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 22] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 23] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 24] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 25] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 26] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 27] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 28] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 29] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 30] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 31] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for [T; 32] where
    T: ToPyObject
[src]

impl<T> IntoPy<PyObject> for Vec<T> where
    T: IntoPy<PyObject>, 
[src]

impl IntoPy<PyObject> for i8[src]

impl IntoPy<PyObject> for u8[src]

impl IntoPy<PyObject> for i16[src]

impl IntoPy<PyObject> for u16[src]

impl IntoPy<PyObject> for i32[src]

impl IntoPy<PyObject> for u32[src]

impl IntoPy<PyObject> for i64[src]

impl IntoPy<PyObject> for isize[src]

impl IntoPy<PyObject> for usize[src]

impl IntoPy<PyObject> for u64[src]

impl IntoPy<PyObject> for i128[src]

impl IntoPy<PyObject> for u128[src]

impl<'a> IntoPy<PyObject> for &'a str[src]

impl<'a> IntoPy<PyObject> for &'a String[src]

impl<A: IntoPy<PyObject>> IntoPy<PyObject> for (A,)[src]

impl<A: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A,)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>> IntoPy<PyObject> for (A, B)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C, D)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C, D)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C, D, E)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C, D, E)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C, D, E, F)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C, D, E, F)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>, G: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C, D, E, F, G)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>, G: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C, D, E, F, G)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>, G: IntoPy<PyObject>, H: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C, D, E, F, G, H)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>, G: IntoPy<PyObject>, H: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C, D, E, F, G, H)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>, G: IntoPy<PyObject>, H: IntoPy<PyObject>, I: IntoPy<PyObject>> IntoPy<PyObject> for (A, B, C, D, E, F, G, H, I)[src]

impl<A: IntoPy<PyObject>, B: IntoPy<PyObject>, C: IntoPy<PyObject>, D: IntoPy<PyObject>, E: IntoPy<PyObject>, F: IntoPy<PyObject>, G: IntoPy<PyObject>, H: IntoPy<PyObject>, I: IntoPy<PyObject>> IntoPy<Py<PyTuple>> for (A, B, C, D, E, F, G, H, I)[src]

Loading content...

Implementors

impl<'a> IntoPy<PyObject> for &'a PyErr[src]

impl<T> IntoPy<PyObject> for Py<T>[src]

fn into_py(self, _py: Python<'_>) -> PyObject[src]

Converts a Py instance to PyObject. Consumes self without calling Py_DECREF().

impl<T, U> IntoPy<U> for T where
    U: FromPy<T>, 
[src]

Loading content...