Skip to main content

PadSinkHandler

Trait PadSinkHandler 

Source
pub trait PadSinkHandler:
    Clone
    + Send
    + Sync
    + 'static {
    type ElementImpl: ElementImpl<Type: Send>;

    // Provided methods
    fn sink_activate(
        self,
        pad: &Pad,
        _imp: &Self::ElementImpl,
    ) -> Result<(), LoggableError> { ... }
    fn sink_activatemode(
        self,
        _pad: &Pad,
        _imp: &Self::ElementImpl,
        _mode: PadMode,
        _active: bool,
    ) -> Result<(), LoggableError> { ... }
    fn sink_chain(
        self,
        _pad: Pad,
        _elem: <Self::ElementImpl as ObjectSubclass>::Type,
        _buffer: Buffer,
    ) -> impl Future<Output = Result<FlowSuccess, FlowError>> + Send { ... }
    fn sink_chain_list(
        self,
        _pad: Pad,
        _elem: <Self::ElementImpl as ObjectSubclass>::Type,
        _buffer_list: BufferList,
    ) -> impl Future<Output = Result<FlowSuccess, FlowError>> + Send { ... }
    fn sink_event(
        self,
        pad: &Pad,
        imp: &Self::ElementImpl,
        event: Event,
    ) -> bool { ... }
    fn sink_event_serialized(
        self,
        pad: Pad,
        elem: <Self::ElementImpl as ObjectSubclass>::Type,
        event: Event,
    ) -> impl Future<Output = bool> + Send { ... }
    fn sink_event_full(
        self,
        pad: &Pad,
        imp: &Self::ElementImpl,
        event: Event,
    ) -> Result<FlowSuccess, FlowError> { ... }
    fn sink_event_full_serialized(
        self,
        pad: Pad,
        elem: <Self::ElementImpl as ObjectSubclass>::Type,
        event: Event,
    ) -> impl Future<Output = Result<FlowSuccess, FlowError>> + Send { ... }
    fn sink_query(
        self,
        pad: &Pad,
        imp: &Self::ElementImpl,
        query: &mut QueryRef,
    ) -> bool { ... }
}
Expand description

A trait to define handlers for PadSink callbacks.

See the pad module documentation for a description of the model.

Required Associated Types§

Provided Methods§

Source

fn sink_activate( self, pad: &Pad, _imp: &Self::ElementImpl, ) -> Result<(), LoggableError>

Source

fn sink_activatemode( self, _pad: &Pad, _imp: &Self::ElementImpl, _mode: PadMode, _active: bool, ) -> Result<(), LoggableError>

Source

fn sink_chain( self, _pad: Pad, _elem: <Self::ElementImpl as ObjectSubclass>::Type, _buffer: Buffer, ) -> impl Future<Output = Result<FlowSuccess, FlowError>> + Send

Source

fn sink_chain_list( self, _pad: Pad, _elem: <Self::ElementImpl as ObjectSubclass>::Type, _buffer_list: BufferList, ) -> impl Future<Output = Result<FlowSuccess, FlowError>> + Send

Source

fn sink_event(self, pad: &Pad, imp: &Self::ElementImpl, event: Event) -> bool

Source

fn sink_event_serialized( self, pad: Pad, elem: <Self::ElementImpl as ObjectSubclass>::Type, event: Event, ) -> impl Future<Output = bool> + Send

Source

fn sink_event_full( self, pad: &Pad, imp: &Self::ElementImpl, event: Event, ) -> Result<FlowSuccess, FlowError>

Source

fn sink_event_full_serialized( self, pad: Pad, elem: <Self::ElementImpl as ObjectSubclass>::Type, event: Event, ) -> impl Future<Output = Result<FlowSuccess, FlowError>> + Send

Source

fn sink_query( self, pad: &Pad, imp: &Self::ElementImpl, query: &mut QueryRef, ) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§