Trait pyo3::callback::IntoPyCallbackOutput

source ·
pub trait IntoPyCallbackOutput<Target> {
    // Required method
    fn convert(self, py: Python<'_>) -> PyResult<Target>;
}
Expand description

Convert the result of callback function into the appropriate return value.

Required Methods§

source

fn convert(self, py: Python<'_>) -> PyResult<Target>

Implementations on Foreign Types§

source§

impl IntoPyCallbackOutput<bool> for bool

source§

fn convert(self, _: Python<'_>) -> PyResult<bool>

source§

impl IntoPyCallbackOutput<i32> for bool

source§

fn convert(self, _: Python<'_>) -> PyResult<c_int>

source§

impl IntoPyCallbackOutput<i32> for ()

source§

fn convert(self, _: Python<'_>) -> PyResult<c_int>

source§

impl IntoPyCallbackOutput<isize> for usize

source§

fn convert(self, _py: Python<'_>) -> PyResult<Py_ssize_t>

source§

impl IntoPyCallbackOutput<*mut PyObject> for *mut PyObject

source§

fn convert(self, _: Python<'_>) -> PyResult<Self>

source§

impl IntoPyCallbackOutput<()> for ()

source§

fn convert(self, _: Python<'_>) -> PyResult<()>

source§

impl IntoPyCallbackOutput<usize> for usize

source§

fn convert(self, _: Python<'_>) -> PyResult<usize>

source§

impl<T, E, U> IntoPyCallbackOutput<U> for Result<T, E>
where T: IntoPyCallbackOutput<U>, E: Into<PyErr>,

source§

fn convert(self, py: Python<'_>) -> PyResult<U>

Implementors§

⚠️ Internal Docs ⚠️ Not Public API 👉 Official Docs Here