blob: f9bf9ea9a82c466f135718fdc8c6b07241b012d3 [file] [log] [blame]
hbosd565b732016-08-30 14:04:35 -07001/*
2 * Copyright 2016 The WebRTC Project Authors. All rights reserved.
3 *
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
9 */
10
hbos74e1a4f2016-09-15 23:33:01 -070011#ifndef WEBRTC_API_STATS_RTCSTATS_OBJECTS_H_
12#define WEBRTC_API_STATS_RTCSTATS_OBJECTS_H_
hbosd565b732016-08-30 14:04:35 -070013
14#include <string>
15
hbos74e1a4f2016-09-15 23:33:01 -070016#include "webrtc/api/stats/rtcstats.h"
hbosd565b732016-08-30 14:04:35 -070017
18namespace webrtc {
19
hboscc555c52016-10-18 12:48:31 -070020// https://w3c.github.io/webrtc-pc/#idl-def-rtcdatachannelstate
21struct RTCDataChannelState {
22 static const char* kConnecting;
23 static const char* kOpen;
24 static const char* kClosing;
25 static const char* kClosed;
26};
27
hbosc47a0c32016-10-11 14:54:49 -070028// https://w3c.github.io/webrtc-stats/#dom-rtcstatsicecandidatepairstate
29struct RTCStatsIceCandidatePairState {
30 static const char* kFrozen;
31 static const char* kWaiting;
32 static const char* kInProgress;
33 static const char* kFailed;
34 static const char* kSucceeded;
35 static const char* kCancelled;
36};
37
hboscc555c52016-10-18 12:48:31 -070038// https://w3c.github.io/webrtc-pc/#rtcicecandidatetype-enum
hbosab9f6e42016-10-07 02:18:47 -070039struct RTCIceCandidateType {
40 static const char* kHost;
41 static const char* kSrflx;
42 static const char* kPrflx;
43 static const char* kRelay;
44};
45
hbos2fa7c672016-10-24 04:00:05 -070046// https://w3c.github.io/webrtc-stats/#certificatestats-dict*
47class RTCCertificateStats final : public RTCStats {
48 public:
49 WEBRTC_RTCSTATS_DECL();
50
51 RTCCertificateStats(const std::string& id, int64_t timestamp_us);
52 RTCCertificateStats(std::string&& id, int64_t timestamp_us);
53 RTCCertificateStats(const RTCCertificateStats& other);
54 ~RTCCertificateStats() override;
55
56 RTCStatsMember<std::string> fingerprint;
57 RTCStatsMember<std::string> fingerprint_algorithm;
58 RTCStatsMember<std::string> base64_certificate;
59 RTCStatsMember<std::string> issuer_certificate_id;
60};
61
hbos0adb8282016-11-23 02:32:06 -080062// https://w3c.github.io/webrtc-stats/#codec-dict*
63// Tracking bug crbug.com/659117
64// TODO(hbos): The present codec ID assignment is not sufficient to support
65// Unified Plan or unbundled connections in all cases. crbug.com/659117
66class RTCCodecStats final : public RTCStats {
67 public:
68 WEBRTC_RTCSTATS_DECL();
69
70 RTCCodecStats(const std::string& id, int64_t timestamp_us);
71 RTCCodecStats(std::string&& id, int64_t timestamp_us);
72 RTCCodecStats(const RTCCodecStats& other);
73 ~RTCCodecStats() override;
74
75 RTCStatsMember<uint32_t> payload_type;
76 RTCStatsMember<std::string> codec;
77 RTCStatsMember<uint32_t> clock_rate;
78 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659117
79 RTCStatsMember<uint32_t> channels;
80 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659117
81 RTCStatsMember<std::string> parameters;
82 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659117
83 RTCStatsMember<std::string> implementation;
84};
85
hbos2fa7c672016-10-24 04:00:05 -070086// https://w3c.github.io/webrtc-stats/#dcstats-dict*
87class RTCDataChannelStats final : public RTCStats {
88 public:
89 WEBRTC_RTCSTATS_DECL();
90
91 RTCDataChannelStats(const std::string& id, int64_t timestamp_us);
92 RTCDataChannelStats(std::string&& id, int64_t timestamp_us);
93 RTCDataChannelStats(const RTCDataChannelStats& other);
94 ~RTCDataChannelStats() override;
95
96 RTCStatsMember<std::string> label;
97 RTCStatsMember<std::string> protocol;
98 RTCStatsMember<int32_t> datachannelid;
99 // TODO(hbos): Support enum types? "RTCStatsMember<RTCDataChannelState>"?
100 RTCStatsMember<std::string> state;
101 RTCStatsMember<uint32_t> messages_sent;
102 RTCStatsMember<uint64_t> bytes_sent;
103 RTCStatsMember<uint32_t> messages_received;
104 RTCStatsMember<uint64_t> bytes_received;
105};
106
107// https://w3c.github.io/webrtc-stats/#candidatepair-dict*
hbos0adb8282016-11-23 02:32:06 -0800108// TODO(hbos): Tracking bug crbug.com/633550
hbos6ded1902016-11-01 01:50:46 -0700109class RTCIceCandidatePairStats final : public RTCStats {
hbosc47a0c32016-10-11 14:54:49 -0700110 public:
111 WEBRTC_RTCSTATS_DECL();
112
113 RTCIceCandidatePairStats(const std::string& id, int64_t timestamp_us);
114 RTCIceCandidatePairStats(std::string&& id, int64_t timestamp_us);
115 RTCIceCandidatePairStats(const RTCIceCandidatePairStats& other);
116 ~RTCIceCandidatePairStats() override;
117
hbos5d79a7c2016-10-24 09:27:10 -0700118 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550, 653873
hbosc47a0c32016-10-11 14:54:49 -0700119 RTCStatsMember<std::string> transport_id;
120 RTCStatsMember<std::string> local_candidate_id;
121 RTCStatsMember<std::string> remote_candidate_id;
122 // TODO(hbos): Support enum types?
123 // "RTCStatsMember<RTCStatsIceCandidatePairState>"?
hbos5d79a7c2016-10-24 09:27:10 -0700124 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700125 RTCStatsMember<std::string> state;
hbos5d79a7c2016-10-24 09:27:10 -0700126 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700127 RTCStatsMember<uint64_t> priority;
hbos5d79a7c2016-10-24 09:27:10 -0700128 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700129 RTCStatsMember<bool> nominated;
hbos5d79a7c2016-10-24 09:27:10 -0700130 // TODO(hbos): Collected by |RTCStatsCollector| but different than the spec.
131 // crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700132 RTCStatsMember<bool> writable;
hbos5d79a7c2016-10-24 09:27:10 -0700133 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700134 RTCStatsMember<bool> readable;
135 RTCStatsMember<uint64_t> bytes_sent;
136 RTCStatsMember<uint64_t> bytes_received;
hbos5d79a7c2016-10-24 09:27:10 -0700137 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700138 RTCStatsMember<double> total_rtt;
hbos5d79a7c2016-10-24 09:27:10 -0700139 // TODO(hbos): Collected by |RTCStatsCollector| but different than the spec.
140 // crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700141 RTCStatsMember<double> current_rtt;
hbos5d79a7c2016-10-24 09:27:10 -0700142 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700143 RTCStatsMember<double> available_outgoing_bitrate;
hbos5d79a7c2016-10-24 09:27:10 -0700144 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700145 RTCStatsMember<double> available_incoming_bitrate;
hbos5d79a7c2016-10-24 09:27:10 -0700146 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700147 RTCStatsMember<uint64_t> requests_received;
148 RTCStatsMember<uint64_t> requests_sent;
149 RTCStatsMember<uint64_t> responses_received;
150 RTCStatsMember<uint64_t> responses_sent;
hbos5d79a7c2016-10-24 09:27:10 -0700151 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700152 RTCStatsMember<uint64_t> retransmissions_received;
hbos5d79a7c2016-10-24 09:27:10 -0700153 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700154 RTCStatsMember<uint64_t> retransmissions_sent;
hbos5d79a7c2016-10-24 09:27:10 -0700155 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700156 RTCStatsMember<uint64_t> consent_requests_received;
hbos5d79a7c2016-10-24 09:27:10 -0700157 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700158 RTCStatsMember<uint64_t> consent_requests_sent;
hbos5d79a7c2016-10-24 09:27:10 -0700159 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700160 RTCStatsMember<uint64_t> consent_responses_received;
hbos5d79a7c2016-10-24 09:27:10 -0700161 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/633550
hbosc47a0c32016-10-11 14:54:49 -0700162 RTCStatsMember<uint64_t> consent_responses_sent;
163};
164
hbosab9f6e42016-10-07 02:18:47 -0700165// https://w3c.github.io/webrtc-stats/#icecandidate-dict*
hbos5d79a7c2016-10-24 09:27:10 -0700166// TODO(hbos): |RTCStatsCollector| only collects candidates that are part of
167// ice candidate pairs, but there could be candidates not paired with anything.
168// crbug.com/632723
hbosab9f6e42016-10-07 02:18:47 -0700169class RTCIceCandidateStats : public RTCStats {
170 public:
171 WEBRTC_RTCSTATS_DECL();
172
173 RTCIceCandidateStats(const RTCIceCandidateStats& other);
174 ~RTCIceCandidateStats() override;
175
176 RTCStatsMember<std::string> ip;
177 RTCStatsMember<int32_t> port;
178 RTCStatsMember<std::string> protocol;
179 // TODO(hbos): Support enum types? "RTCStatsMember<RTCIceCandidateType>"?
180 RTCStatsMember<std::string> candidate_type;
181 RTCStatsMember<int32_t> priority;
hbos5d79a7c2016-10-24 09:27:10 -0700182 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/632723
hbosab9f6e42016-10-07 02:18:47 -0700183 RTCStatsMember<std::string> url;
184
185 protected:
186 RTCIceCandidateStats(const std::string& id, int64_t timestamp_us);
187 RTCIceCandidateStats(std::string&& id, int64_t timestamp_us);
188};
189
190// In the spec both local and remote varieties are of type RTCIceCandidateStats.
191// But here we define them as subclasses of |RTCIceCandidateStats| because the
192// |kType| need to be different ("RTCStatsType type") in the local/remote case.
193// https://w3c.github.io/webrtc-stats/#rtcstatstype-str*
194class RTCLocalIceCandidateStats final : public RTCIceCandidateStats {
195 public:
196 static const char kType[];
197 RTCLocalIceCandidateStats(const std::string& id, int64_t timestamp_us);
198 RTCLocalIceCandidateStats(std::string&& id, int64_t timestamp_us);
199 const char* type() const override;
200};
201
202class RTCRemoteIceCandidateStats final : public RTCIceCandidateStats {
203 public:
204 static const char kType[];
205 RTCRemoteIceCandidateStats(const std::string& id, int64_t timestamp_us);
206 RTCRemoteIceCandidateStats(std::string&& id, int64_t timestamp_us);
207 const char* type() const override;
208};
209
hbos09bc1282016-11-08 06:29:22 -0800210// https://w3c.github.io/webrtc-stats/#msstats-dict*
hbos0adb8282016-11-23 02:32:06 -0800211// TODO(hbos): Tracking bug crbug.com/660827
hbos09bc1282016-11-08 06:29:22 -0800212class RTCMediaStreamStats final : public RTCStats {
213 public:
214 WEBRTC_RTCSTATS_DECL();
215
216 RTCMediaStreamStats(const std::string& id, int64_t timestamp_us);
217 RTCMediaStreamStats(std::string&& id, int64_t timestamp_us);
218 RTCMediaStreamStats(const RTCMediaStreamStats& other);
219 ~RTCMediaStreamStats() override;
220
221 RTCStatsMember<std::string> stream_identifier;
222 RTCStatsMember<std::vector<std::string>> track_ids;
223};
224
225// https://w3c.github.io/webrtc-stats/#mststats-dict*
hbos0adb8282016-11-23 02:32:06 -0800226// TODO(hbos): Tracking bug crbug.com/659137
hbos09bc1282016-11-08 06:29:22 -0800227class RTCMediaStreamTrackStats final : public RTCStats {
228 public:
229 WEBRTC_RTCSTATS_DECL();
230
231 RTCMediaStreamTrackStats(const std::string& id, int64_t timestamp_us);
232 RTCMediaStreamTrackStats(std::string&& id, int64_t timestamp_us);
233 RTCMediaStreamTrackStats(const RTCMediaStreamTrackStats& other);
234 ~RTCMediaStreamTrackStats() override;
235
236 RTCStatsMember<std::string> track_identifier;
237 RTCStatsMember<bool> remote_source;
238 RTCStatsMember<bool> ended;
239 // TODO(hbos): |RTCStatsCollector| does not return stats for detached tracks.
240 // crbug.com/659137
241 RTCStatsMember<bool> detached;
242 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
243 RTCStatsMember<std::vector<std::string>> ssrc_ids;
244 // Video-only members
245 RTCStatsMember<uint32_t> frame_width;
246 RTCStatsMember<uint32_t> frame_height;
247 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
248 RTCStatsMember<double> frames_per_second;
249 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
250 RTCStatsMember<uint32_t> frames_sent;
251 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
252 RTCStatsMember<uint32_t> frames_received;
253 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
254 RTCStatsMember<uint32_t> frames_decoded;
255 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
256 RTCStatsMember<uint32_t> frames_dropped;
257 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
258 RTCStatsMember<uint32_t> frames_corrupted;
259 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
260 RTCStatsMember<uint32_t> partial_frames_lost;
261 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/659137
262 RTCStatsMember<uint32_t> full_frames_lost;
263 // Audio-only members
264 RTCStatsMember<double> audio_level;
265 RTCStatsMember<double> echo_return_loss;
266 RTCStatsMember<double> echo_return_loss_enhancement;
267};
268
hbos6ab97ce2016-10-03 14:16:56 -0700269// https://w3c.github.io/webrtc-stats/#pcstats-dict*
hbos0adb8282016-11-23 02:32:06 -0800270// TODO(hbos): Tracking bug crbug.com/636818
hbosab9f6e42016-10-07 02:18:47 -0700271class RTCPeerConnectionStats final : public RTCStats {
hbosd565b732016-08-30 14:04:35 -0700272 public:
hbosfc5e0502016-10-06 02:06:10 -0700273 WEBRTC_RTCSTATS_DECL();
274
hbos0e6758d2016-08-31 07:57:36 -0700275 RTCPeerConnectionStats(const std::string& id, int64_t timestamp_us);
276 RTCPeerConnectionStats(std::string&& id, int64_t timestamp_us);
hbosfc5e0502016-10-06 02:06:10 -0700277 RTCPeerConnectionStats(const RTCPeerConnectionStats& other);
278 ~RTCPeerConnectionStats() override;
hbosd565b732016-08-30 14:04:35 -0700279
hbos5d79a7c2016-10-24 09:27:10 -0700280 // TODO(hbos): Collected by |RTCStatsCollector| but different than the spec.
281 // crbug.com/636818
hbosd565b732016-08-30 14:04:35 -0700282 RTCStatsMember<uint32_t> data_channels_opened;
hbos5d79a7c2016-10-24 09:27:10 -0700283 // TODO(hbos): Collected by |RTCStatsCollector| but different than the spec.
284 // crbug.com/636818
hbosd565b732016-08-30 14:04:35 -0700285 RTCStatsMember<uint32_t> data_channels_closed;
286};
287
hbos6ded1902016-11-01 01:50:46 -0700288// https://w3c.github.io/webrtc-stats/#streamstats-dict*
hbos0adb8282016-11-23 02:32:06 -0800289// TODO(hbos): Tracking bug crbug.com/657854
hbos6ded1902016-11-01 01:50:46 -0700290class RTCRTPStreamStats : public RTCStats {
291 public:
292 WEBRTC_RTCSTATS_DECL();
293
294 RTCRTPStreamStats(const RTCRTPStreamStats& other);
295 ~RTCRTPStreamStats() override;
296
297 RTCStatsMember<std::string> ssrc;
298 // TODO(hbos): When the remote case is supported |RTCStatsCollector| needs to
299 // set this. crbug.com/657855, 657856
300 RTCStatsMember<std::string> associate_stats_id;
301 // TODO(hbos): Remote case not supported by |RTCStatsCollector|.
302 // crbug.com/657855, 657856
303 RTCStatsMember<bool> is_remote; // = false
304 RTCStatsMember<std::string> media_type;
305 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657854, 659137
306 RTCStatsMember<std::string> media_track_id;
307 RTCStatsMember<std::string> transport_id;
hbos6ded1902016-11-01 01:50:46 -0700308 RTCStatsMember<std::string> codec_id;
309 // FIR and PLI counts are only defined for |media_type == "video"|.
310 RTCStatsMember<uint32_t> fir_count;
311 RTCStatsMember<uint32_t> pli_count;
312 // TODO(hbos): NACK count should be collected by |RTCStatsCollector| for both
313 // audio and video but is only defined in the "video" case. crbug.com/657856
314 RTCStatsMember<uint32_t> nack_count;
315 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657854
316 // SLI count is only defined for |media_type == "video"|.
317 RTCStatsMember<uint32_t> sli_count;
318
319 protected:
320 RTCRTPStreamStats(const std::string& id, int64_t timestamp_us);
321 RTCRTPStreamStats(std::string&& id, int64_t timestamp_us);
322};
323
hboseeafe942016-11-01 03:00:17 -0700324// https://w3c.github.io/webrtc-stats/#inboundrtpstats-dict*
hbos0adb8282016-11-23 02:32:06 -0800325// Tracking bug crbug.com/657855
326// TODO(hbos): Support the remote case |is_remote = true|. crbug.com/657855
hboseeafe942016-11-01 03:00:17 -0700327class RTCInboundRTPStreamStats final : public RTCRTPStreamStats {
328 public:
329 WEBRTC_RTCSTATS_DECL();
330
331 RTCInboundRTPStreamStats(const std::string& id, int64_t timestamp_us);
332 RTCInboundRTPStreamStats(std::string&& id, int64_t timestamp_us);
333 RTCInboundRTPStreamStats(const RTCInboundRTPStreamStats& other);
334 ~RTCInboundRTPStreamStats() override;
335
336 RTCStatsMember<uint32_t> packets_received;
337 RTCStatsMember<uint64_t> bytes_received;
338 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
339 RTCStatsMember<uint32_t> packets_lost;
340 // TODO(hbos): Not collected in the "video" case by |RTCStatsCollector|.
341 // crbug.com/657855
342 RTCStatsMember<double> jitter;
343 RTCStatsMember<double> fraction_lost;
344 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
345 RTCStatsMember<uint32_t> packets_discarded;
346 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
347 RTCStatsMember<uint32_t> packets_repaired;
348 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
349 RTCStatsMember<uint32_t> burst_packets_lost;
350 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
351 RTCStatsMember<uint32_t> burst_packets_discarded;
352 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
353 RTCStatsMember<uint32_t> burst_loss_count;
354 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
355 RTCStatsMember<uint32_t> burst_discard_count;
356 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
357 RTCStatsMember<double> burst_loss_rate;
358 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
359 RTCStatsMember<double> burst_discard_rate;
360 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
361 RTCStatsMember<double> gap_loss_rate;
362 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657855
363 RTCStatsMember<double> gap_discard_rate;
364};
365
hbos6ded1902016-11-01 01:50:46 -0700366// https://w3c.github.io/webrtc-stats/#outboundrtpstats-dict*
hbos0adb8282016-11-23 02:32:06 -0800367// Tracking bug crbug.com/657856
368// TODO(hbos): Support the remote case |is_remote = true|. crbug.com/657856
hbos6ded1902016-11-01 01:50:46 -0700369class RTCOutboundRTPStreamStats final : public RTCRTPStreamStats {
370 public:
371 WEBRTC_RTCSTATS_DECL();
372
373 RTCOutboundRTPStreamStats(const std::string& id, int64_t timestamp_us);
374 RTCOutboundRTPStreamStats(std::string&& id, int64_t timestamp_us);
375 RTCOutboundRTPStreamStats(const RTCOutboundRTPStreamStats& other);
376 ~RTCOutboundRTPStreamStats() override;
377
378 RTCStatsMember<uint32_t> packets_sent;
379 RTCStatsMember<uint64_t> bytes_sent;
380 // TODO(hbos): Not collected by |RTCStatsCollector|. crbug.com/657856
381 RTCStatsMember<double> target_bitrate;
382 RTCStatsMember<double> round_trip_time;
383};
384
hbos2fa7c672016-10-24 04:00:05 -0700385// https://w3c.github.io/webrtc-stats/#transportstats-dict*
386class RTCTransportStats final : public RTCStats {
387 public:
388 WEBRTC_RTCSTATS_DECL();
389
390 RTCTransportStats(const std::string& id, int64_t timestamp_us);
391 RTCTransportStats(std::string&& id, int64_t timestamp_us);
392 RTCTransportStats(const RTCTransportStats& other);
393 ~RTCTransportStats() override;
394
395 RTCStatsMember<uint64_t> bytes_sent;
396 RTCStatsMember<uint64_t> bytes_received;
397 RTCStatsMember<std::string> rtcp_transport_stats_id;
398 RTCStatsMember<bool> active_connection;
399 RTCStatsMember<std::string> selected_candidate_pair_id;
400 RTCStatsMember<std::string> local_certificate_id;
401 RTCStatsMember<std::string> remote_certificate_id;
402};
403
hbosd565b732016-08-30 14:04:35 -0700404} // namespace webrtc
405
hbos74e1a4f2016-09-15 23:33:01 -0700406#endif // WEBRTC_API_STATS_RTCSTATS_OBJECTS_H_