# pyo3::class::descr::PyDescrProtocol - Rust
Descriptor interface
Keywords: rust, rustlang, rust-lang, PyDescrProtocol

# Trait pyo3::class::descr::PyDescrProtocol [−] [src]

    pub trait PyDescrProtocol<'p>: PyClass {
        fn __get__(
            slf: Self::Receiver,
            instance: Self::Inst,
            owner: Option<Self::Owner>
        ) -> Self::Result
        where
            Self: PyDescrGetProtocol<'p>,
        { ... }
        fn __set__(
            slf: Self::Receiver,
            instance: Self::Inst,
            value: Self::Value
        ) -> Self::Result
        where
            Self: PyDescrSetProtocol<'p>,
        { ... }
        fn __delete__(&'p self, instance: &'p PyAny) -> Self::Result
        where
            Self: PyDescrDeleteProtocol<'p>,
        { ... }
        fn __set_name__(&'p self, instance: &'p PyAny) -> Self::Result
        where
            Self: PyDescrSetNameProtocol<'p>,
        { ... }
    }

Descriptor interface

## Provided methods

### `fn __get__(
slf: Self::Receiver,
instance: Self::Inst,
owner: Option<Self::Owner>
) -> Self::Result where
Self: PyDescrGetProtocol<'p>,` [src]

### `fn __set__(
slf: Self::Receiver,
instance: Self::Inst,
value: Self::Value
) -> Self::Result where
Self: PyDescrSetProtocol<'p>,` [src]

### `fn __delete__(&'p self, instance: &'p PyAny) -> Self::Result where
Self: PyDescrDeleteProtocol<'p>,` [src]

### `fn __set_name__(&'p self, instance: &'p PyAny) -> Self::Result where
Self: PyDescrSetNameProtocol<'p>,` [src]

Loading content...

## Implementors

Loading content...