Class PublisherKit.PublisherRtcStats

  • Enclosing class:
    PublisherKit

    public static class PublisherKit.PublisherRtcStats
    extends java.lang.Object
    Represents RTC statistics for a media stream published by the publisher.
    See Also:
    PublisherKit.getRtcStatsReport()
    • Field Summary

      Fields 
      Modifier and Type Field Description
      java.lang.String connectionId
      For a relayed session (in which a publisher sends individual media streams to each subscriber), this is the unique ID of the client's connection.
      java.lang.String jsonArrayOfReports
      A JSON array of RTC stats reports for the media stream.
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • connectionId

        public java.lang.String connectionId
        For a relayed session (in which a publisher sends individual media streams to each subscriber), this is the unique ID of the client's connection.
      • jsonArrayOfReports

        public java.lang.String jsonArrayOfReports
        A JSON array of RTC stats reports for the media stream. The structure of the JSON array is similar to the format of the RtcStatsReport object implemented in web browsers (see Mozilla docs). Also see this W3C documentation.

        Here is a partial sample:

          [
             {
                 "audioLevel": 0,
                 "id": "RTCAudioSource_1",
                 "kind": "audio",
                 "timestamp": 1603448671532842,
                 "totalAudioEnergy": 0,
                 "totalSamplesDuration": 4.249999999999954,
                 "trackIdentifier": "4nP5yeIDzbUm6IJho5jkTps1lnfabsFvTXjH00",
                 "type": "media-source"
             },
             {
                 "base64Certificate": "MIIBFjCB...QIhAMIfr/NgvhNp16zaoHxGQGrID1STFmBSSSB4V1bxBrTU",
                 "fingerprint": "E7:5F:...:FA:5A:1F:A7:E0:55:60",
                 "fingerprintAlgorithm": "sha-256",
                 "id": "RTCCertificate_E7:5F:E5...F:1D:FA:5A:1F:A7:E0:55:60",
                 "timestamp": 1603448671532842,
                 "type": "certificate"
             },
             {
                 "channels": 1,
                 "clockRate": 8000,
                 "id": "RTCCodec_audio_Inbound_0",
                 "mimeType": "audio/PCMU",
                 "payloadType": 0,
                 "timestamp": 1603448671532842,
                 "type": "codec"
             },
             {
                 "channels": 2,
                 "clockRate": 48000,
                 "id": "RTCCodec_audio_Inbound_111",
                 "mimeType": "audio/opus",
                 "payloadType": 111,
                 "sdpFmtpLine": "minptime=10;useinbandfec=1",
                 "timestamp": 1603448671532842,
                 "type": "codec"
             },
          ]
          
    • Constructor Detail

      • PublisherRtcStats

        public PublisherRtcStats()