Trait pyo3::impl_::wrap::OkWrap

source ·
pub trait OkWrap<T> {
    type Error;

    // Required method
    fn wrap(self) -> Result<T, Self::Error>;
}
Expand description

Used to wrap the result of #[pyfunction] and #[pymethods].

Required Associated Types§

Required Methods§

source

fn wrap(self) -> Result<T, Self::Error>

Implementations on Foreign Types§

source§

impl<T, E> OkWrap<T> for Result<T, E>
where T: IntoPy<PyObject>,

§

type Error = E

source§

fn wrap(self) -> Result<T, Self::Error>

Implementors§

source§

impl<T> OkWrap<T> for T
where T: IntoPy<PyObject>,

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