HasProxy

Trait HasProxy 

Source
pub trait HasProxy:
    Any
    + Send
    + Sync {
    // Required methods
    fn type_(&self) -> ObjectType;
    fn version(&self) -> u32;
    fn proxy(&self) -> Proxy<Self>
       where Self: Refcounted;
}
Expand description

This trait is implemented by all specific types of proxies. See the Proxy documentation for more details.

Required Methods§

Source

fn type_(&self) -> ObjectType

The interface type of the proxy object.

Source

fn version(&self) -> u32

The interface version of the proxy object.

Source

fn proxy(&self) -> Proxy<Self>
where Self: Refcounted,

Get a Proxy<T> for this object.

Implementations§

Source§

impl dyn HasProxy

Source

pub fn downcast<T: HasProxy + Refcounted>(&self) -> Option<T>

Downcast from a dyn HasProxy to the specific type.

Source

pub fn downcast_proxy<T: HasProxy + Refcounted>(&self) -> Option<Proxy<T>>

Downcast from a dyn HasProxy to the corresponding Proxy type.

Implementors§