Class StreamRTPManager


  • public class StreamRTPManager
    extends Object
    Implements the RTPManager interface as used by a MediaStream.
    Author:
    Lyubomir Marinov
    • Constructor Detail

      • StreamRTPManager

        public StreamRTPManager​(MediaStream stream,
                                RTPTranslator translator)
        Initializes a new StreamRTPManager instance which is, optionally, attached to a specific RTPTranslator which is to forward the RTP and RTCP flows of the associated MediaStream to other MediaStreams.
        Parameters:
        stream - the MediaStream that created this StreamRTPManager.
        translator - the RTPTranslator to attach the new instance to or null if the new instance is to not be attached to any RTPTranslator
    • Method Detail

      • addFormat

        public void addFormat​(javax.media.Format format,
                              int payloadType)
      • addReceiveStreamListener

        public void addReceiveStreamListener​(javax.media.rtp.ReceiveStreamListener listener)
      • addRemoteListener

        public void addRemoteListener​(javax.media.rtp.RemoteListener listener)
      • addSendStreamListener

        public void addSendStreamListener​(javax.media.rtp.SendStreamListener listener)
      • addSessionListener

        public void addSessionListener​(javax.media.rtp.SessionListener listener)
      • createSendStream

        public javax.media.rtp.SendStream createSendStream​(javax.media.protocol.DataSource dataSource,
                                                           int streamIndex)
                                                    throws IOException,
                                                           javax.media.format.UnsupportedFormatException
        Throws:
        IOException
        javax.media.format.UnsupportedFormatException
      • dispose

        public void dispose()
      • getControl

        public <T> T getControl​(Class<T> controlType)
        Gets a control of a specific type over this instance. Invokes getControl(String).
        Parameters:
        controlType - a Class which specifies the type of the control over this instance to get
        Returns:
        a control of the specified controlType over this instance if this instance supports such a control; otherwise, null
      • getControl

        public Object getControl​(String controlType)
        Gets a control of a specific type over this instance.
        Parameters:
        controlType - a String which specifies the type (i.e. the name of the class) of the control over this instance to get
        Returns:
        a control of the specified controlType over this instance if this instance supports such a control; otherwise, null
      • getGlobalReceptionStats

        public javax.media.rtp.GlobalReceptionStats getGlobalReceptionStats()
      • getGlobalTransmissionStats

        public javax.media.rtp.GlobalTransmissionStats getGlobalTransmissionStats()
      • getLocalSSRC

        public long getLocalSSRC()
      • getMediaStream

        public MediaStream getMediaStream()
        Returns the MediaStream that uses this StreamRTPManager
        Returns:
        the MediaStream that uses this StreamRTPManager
      • getReceiveStreams

        public Vector getReceiveStreams()
      • getSendStreams

        public Vector getSendStreams()
      • initialize

        public void initialize​(javax.media.rtp.RTPConnector connector)
      • removeReceiveStreamListener

        public void removeReceiveStreamListener​(javax.media.rtp.ReceiveStreamListener listener)
      • removeRemoteListener

        public void removeRemoteListener​(javax.media.rtp.RemoteListener listener)
      • removeSendStreamListener

        public void removeSendStreamListener​(javax.media.rtp.SendStreamListener listener)
      • removeSessionListener

        public void removeSessionListener​(javax.media.rtp.SessionListener listener)
      • setSSRCFactory

        public void setSSRCFactory​(SSRCFactory ssrcFactory)
        Sets the SSRCFactory to be utilized by this instance to generate new synchronization source (SSRC) identifiers.
        Parameters:
        ssrcFactory - the SSRCFactory to be utilized by this instance to generate new synchronization source (SSRC) identifiers or null if this instance is to employ internal logic to generate new synchronization source (SSRC) identifiers