Struct pyo3::PyObjectRef[][src]

pub struct PyObjectRef(_);

Represents general python instance.

Trait Implementations

impl<U> PyTryInto<U> for PyObjectRef where
    U: PyTryFrom
[src]

The type returned in the event of a conversion error.

Cast from PyObject to a concrete Python object type.

Cast from PyObject to a concrete Python object type. With exact type check.

Cast from PyObject to a concrete Python object type.

Cast from PyObject to a concrete Python object type. With exact type check.

impl AsPyRef<PyObjectRef> for PyObject
[src]

Return reference to object.

Return mutable reference to object.

Acquire python gil and call closure with object reference.

Acquire python gil and call closure with mutable object reference.

impl<'a> From<&'a PyType> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyType
[src]

Performs the conversion.

impl<'a> From<&'a PyModule> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyModule
[src]

Performs the conversion.

impl<'a> From<&'a PyDict> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyDict
[src]

Performs the conversion.

impl<'a> From<&'a PyBool> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyBool
[src]

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for bool
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'a> From<&'a PyByteArray> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyByteArray
[src]

Performs the conversion.

impl<'a> From<&'a PyTuple> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyTuple
[src]

Performs the conversion.

impl<'a> From<&'a PyList> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyList
[src]

Performs the conversion.

impl<'a> From<&'a PyFloat> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyFloat
[src]

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for f64
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for f32
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl AsRef<PyObjectRef> for PySequence
[src]

Performs the conversion.

impl<'a> From<&'a PySlice> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PySlice
[src]

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for String
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'a> From<&'a PySet> for &'a PyObjectRef
[src]

Performs the conversion.

impl<'a> From<&'a PyFrozenSet> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PySet
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyFrozenSet
[src]

Performs the conversion.

impl<'a> From<&'a PyLong> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyLong
[src]

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for i8
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for u8
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for i16
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for u16
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for i32
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for u32
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for i64
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for isize
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'source> TryFrom<&'source PyObjectRef> for usize
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

🔬 This is a nightly-only experimental API. (try_from)

Performs the conversion.

impl<'a> From<&'a PyString> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyString
[src]

Performs the conversion.

impl<'a> From<&'a PyBytes> for &'a PyObjectRef
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyBytes
[src]

Performs the conversion.

impl AsRef<PyObjectRef> for PyObjectRef
[src]

Performs the conversion.

impl PyObjectWithToken for PyObjectRef
[src]

impl ToPyPointer for PyObjectRef
[src]

Gets the underlying FFI pointer, returns a borrowed pointer.

impl PartialEq for PyObjectRef
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl PyTypeInfo for PyObjectRef
[src]

Type of objects to store in PyObject struct

Base class

NAME: &'static str = "PyObjectRef"

Class name

SIZE: usize = ::std::mem::size_of::<::ffi::PyObject>()

Size of the rust PyObject structure (PyObject + rust structure)

OFFSET: isize = 0

Type instance offset inside PyObject structure

PyTypeObject instance for this type

Check if *mut ffi::PyObject is instance of this type

DESCRIPTION: &'static str = "\u{0}"

Class doc string

FLAGS: usize = 0

Type flags (ie PY_TYPE_FLAG_GC, PY_TYPE_FLAG_WEAKREF)

Check if *mut ffi::PyObject is exact instance of this type

impl PyTypeObject for PyObjectRef
[src]

Initialize type object

Retrieves the type object for this Python object type.

Create PyRawObject which can be initialized with rust value

impl ToPyObject for PyObjectRef
[src]

Converts self into a Python object.

impl ToBorrowedObject for PyObjectRef
[src]

Converts self into a Python object and calls the specified closure on the native FFI pointer underlying the Python object. Read more

impl Debug for PyObjectRef
[src]

Formats the value using the given formatter. Read more

impl Display for PyObjectRef
[src]

Formats the value using the given formatter. Read more

impl<'a> FromPyObject<'a> for &'a PyObjectRef
[src]

Extracts Self from the source PyObject.

Auto Trait Implementations

impl Send for PyObjectRef

impl Sync for PyObjectRef