Trait gstreamer_rtsp_server::RTSPSessionPoolExt[][src]

pub trait RTSPSessionPoolExt {
    fn cleanup(&self) -> u32;
fn create(&self) -> Option<RTSPSession>;
fn find(&self, sessionid: &str) -> Option<RTSPSession>;
fn get_max_sessions(&self) -> u32;
fn get_n_sessions(&self) -> u32;
fn remove(&self, sess: &RTSPSession) -> Result<(), BoolError>;
fn set_max_sessions(&self, max: u32);
fn connect_session_removed<F: Fn(&Self, &RTSPSession) + Send + Sync + 'static>(
        &self,
        f: F
    ) -> SignalHandlerId;
fn connect_property_max_sessions_notify<F: Fn(&Self) + Send + Sync + 'static>(
        &self,
        f: F
    ) -> SignalHandlerId; }

Trait containing all RTSPSessionPool methods.

Implementors

RTSPSessionPool

Required Methods

Inspect all the sessions in self and remove the sessions that are inactive for more than their timeout.

Returns

the amount of sessions that got removed.

Create a new RTSPSession object in self.

Returns

a new RTSPSession.

Find the session with sessionid in self. The access time of the session will be updated with RTSPSessionExt::touch.

sessionid

the session id

Returns

the RTSPSession with sessionid or None when the session did not exist. gobject::ObjectExt::unref after usage.

Get the maximum allowed number of sessions in self. 0 means an unlimited amount of sessions.

Returns

the maximum allowed number of sessions.

Get the amount of active sessions in self.

Returns

the amount of active sessions in self.

Remove sess from self, releasing the ref that the pool has on sess.

sess

a RTSPSession

Returns

true if the session was found and removed.

Configure the maximum allowed number of sessions in self to max. A value of 0 means an unlimited amount of sessions.

max

the maximum number of sessions

Implementors