This trait represents that we can do zero-cost conversion from the object
to a FFI pointer.
This trait is implemented for types that internally wrap a pointer to a Python object.
use pyo3::{AsPyPointer, prelude::*};
let gil = Python::acquire_gil();
let dict = pyo3::types::PyDict::new(gil.python());
assert_ne!(dict.as_ptr(), std::ptr::null_mut());
Retrieves the underlying FFI pointer (as a borrowed pointer).
Loading content...Convert None
into a null pointer.
Loading content...Gets the underlying FFI pointer, returns a borrowed pointer.
impl AsPyPointer for PyAny
[src]
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
impl AsPyPointer for PySet
[src]
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
Gets the underlying FFI pointer, returns a borrowed pointer.
impl<'a, T: PyClass> AsPyPointer for PyRef<'a, T>
[src]
impl<T> AsPyPointer for Py<T>
[src]
Gets the underlying FFI pointer, returns a borrowed pointer.
Loading content...