gstreamer_rtsp_server/
rtsp_onvif_media_factory.rs

1// Take a look at the license at the top of the repository in the LICENSE file.
2
3use glib::{prelude::*, translate::*};
4
5use crate::{ffi, RTSPContext, RTSPOnvifMediaFactory};
6
7mod sealed {
8    pub trait Sealed {}
9    impl<T: super::IsA<super::RTSPOnvifMediaFactory>> Sealed for T {}
10}
11
12pub trait RTSPOnvifMediaFactoryExtManual:
13    sealed::Sealed + IsA<RTSPOnvifMediaFactory> + 'static
14{
15    #[doc(alias = "gst_rtsp_onvif_media_factory_requires_backchannel")]
16    fn requires_backchannel(&self, ctx: &RTSPContext) -> bool {
17        skip_assert_initialized!();
18        unsafe {
19            from_glib(ffi::gst_rtsp_onvif_media_factory_requires_backchannel(
20                self.as_ref()
21                    .upcast_ref::<crate::RTSPMediaFactory>()
22                    .to_glib_none()
23                    .0,
24                ctx.to_glib_none().0,
25            ))
26        }
27    }
28}
29
30impl<O: IsA<RTSPOnvifMediaFactory>> RTSPOnvifMediaFactoryExtManual for O {}