[][src]Trait pyo3::prelude::FromPy

pub trait FromPy<T>: Sized {
    fn from_py(_: T, py: Python) -> Self;

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

Required methods

fn from_py(_: T, py: Python) -> Self

Performs the conversion.

Loading content...


impl FromPy<bool> for PyObject[src]

impl FromPy<f32> for PyObject[src]

impl FromPy<f64> for PyObject[src]

impl FromPy<()> for Py<PyTuple>[src]

Converts () to an empty Python tuple.

impl FromPy<()> for PyObject[src]

impl FromPy<PyErr> for PyObject[src]

impl FromPy<String> for PyObject[src]

impl<'a> FromPy<&'a PyTuple> for Py<PyTuple>[src]

impl<'a> FromPy<&'a [u8]> for PyObject[src]

impl<'a, T> FromPy<&'a T> for PyObject where
    T: AsPyPointer

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

Loading content...