NewTOAPIA.Net.Rtp.RtpSession.CheckForStaleStreams C# (CSharp) Méthode

CheckForStaleStreams() private méthode

Called on the RtcpSender thread every RtcpIntervals So that the session can iterate through the streams and see if they are doing anything
private CheckForStaleStreams ( ) : void
Résultat void
        private void CheckForStaleStreams()
        {
            lock(streamsAndIPs)
            {
                // Streams are stored in a hashtable, you can't remove an item in a foreach loop
                // So make a copy of the streams to iterate on, but delete from the hashtable
                foreach(IPStreamPair ipsp in new ArrayList(streamsAndIPs.Values))
                {
                    if (ipsp.stream != null && ipsp.stream.Stale++ >= RtcpMissedIntervalsTimeout)
                    {
                        RemoveSSRC(ipsp.stream.SSRC);
                    }
                }
            }
        }