UNPKG

kurento-client-core

Version:

JavaScript Client API for Kurento Media Server

114 lines (96 loc) 3.6 kB
/* Autogenerated with Kurento Idl */ /* * (C) Copyright 2013-2015 Kurento (https://kurento.openvidu.io/) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ var inherits = require('inherits'); var kurentoClient = require('kurento-client'); var checkType = kurentoClient.checkType; var ChecktypeError = checkType.ChecktypeError; var RTCRTPStreamStats = require('./RTCRTPStreamStats'); /** * Statistics that represents the measurement metrics for the incoming media * stream. * * @constructor module:core/complexTypes.RTCInboundRTPStreamStats * * @property {external:int64} packetsReceived * Total number of RTP packets received for this SSRC. * @property {external:int64} bytesReceived * Total number of bytes received for this SSRC. * @property {external:double} jitter * Packet Jitter measured in seconds for this SSRC. * @extends module:core.RTCRTPStreamStats */ function RTCInboundRTPStreamStats(rTCInboundRTPStreamStatsDict){ if(!(this instanceof RTCInboundRTPStreamStats)) return new RTCInboundRTPStreamStats(rTCInboundRTPStreamStatsDict) rTCInboundRTPStreamStatsDict = rTCInboundRTPStreamStatsDict || {} // Check rTCInboundRTPStreamStatsDict has the required fields // // checkType('int64', 'rTCInboundRTPStreamStatsDict.packetsReceived', rTCInboundRTPStreamStatsDict.packetsReceived, {required: true}); // // checkType('int64', 'rTCInboundRTPStreamStatsDict.bytesReceived', rTCInboundRTPStreamStatsDict.bytesReceived, {required: true}); // // checkType('double', 'rTCInboundRTPStreamStatsDict.jitter', rTCInboundRTPStreamStatsDict.jitter, {required: true}); // // Init parent class RTCInboundRTPStreamStats.super_.call(this, rTCInboundRTPStreamStatsDict) // Set object properties Object.defineProperties(this, { packetsReceived: { writable: true, enumerable: true, value: rTCInboundRTPStreamStatsDict.packetsReceived }, bytesReceived: { writable: true, enumerable: true, value: rTCInboundRTPStreamStatsDict.bytesReceived }, jitter: { writable: true, enumerable: true, value: rTCInboundRTPStreamStatsDict.jitter } }) } inherits(RTCInboundRTPStreamStats, RTCRTPStreamStats) // Private identifiers to allow re-construction of the complexType on the server // They need to be enumerable so JSON.stringify() can access to them Object.defineProperties(RTCInboundRTPStreamStats.prototype, { __module__: { enumerable: true, value: "kurento" }, __type__: { enumerable: true, value: "RTCInboundRTPStreamStats" } }) /** * Checker for {@link module:core/complexTypes.RTCInboundRTPStreamStats} * * @memberof module:core/complexTypes * * @param {external:String} key * @param {module:core/complexTypes.RTCInboundRTPStreamStats} value */ function checkRTCInboundRTPStreamStats(key, value) { if(!(value instanceof RTCInboundRTPStreamStats)) throw ChecktypeError(key, RTCInboundRTPStreamStats, value); }; module.exports = RTCInboundRTPStreamStats; RTCInboundRTPStreamStats.check = checkRTCInboundRTPStreamStats;