hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 1 | /* |
| 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 | |
Steve Anton | 10542f2 | 2019-01-11 09:11:00 -0800 | [diff] [blame] | 11 | #include "stats/test/rtc_test_stats.h" |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 12 | |
Yves Gerey | 3e70781 | 2018-11-28 16:47:49 +0100 | [diff] [blame] | 13 | #include "rtc_base/checks.h" |
| 14 | |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 15 | namespace webrtc { |
| 16 | |
Yves Gerey | 665174f | 2018-06-19 15:03:05 +0200 | [diff] [blame] | 17 | WEBRTC_RTCSTATS_IMPL(RTCTestStats, |
| 18 | RTCStats, |
| 19 | "test-stats", |
| 20 | &m_bool, |
| 21 | &m_int32, |
| 22 | &m_uint32, |
| 23 | &m_int64, |
| 24 | &m_uint64, |
| 25 | &m_double, |
| 26 | &m_string, |
| 27 | &m_sequence_bool, |
| 28 | &m_sequence_int32, |
| 29 | &m_sequence_uint32, |
| 30 | &m_sequence_int64, |
| 31 | &m_sequence_uint64, |
| 32 | &m_sequence_double, |
Nico Weber | 22f9925 | 2019-02-20 10:13:16 -0500 | [diff] [blame] | 33 | &m_sequence_string) |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 34 | |
| 35 | RTCTestStats::RTCTestStats(const std::string& id, int64_t timestamp_us) |
| 36 | : RTCStats(id, timestamp_us), |
hbos | b20f387 | 2016-10-04 14:37:11 -0700 | [diff] [blame] | 37 | m_bool("mBool"), |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 38 | m_int32("mInt32"), |
| 39 | m_uint32("mUint32"), |
| 40 | m_int64("mInt64"), |
| 41 | m_uint64("mUint64"), |
| 42 | m_double("mDouble"), |
| 43 | m_string("mString"), |
hbos | b20f387 | 2016-10-04 14:37:11 -0700 | [diff] [blame] | 44 | m_sequence_bool("mSequenceBool"), |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 45 | m_sequence_int32("mSequenceInt32"), |
| 46 | m_sequence_uint32("mSequenceUint32"), |
| 47 | m_sequence_int64("mSequenceInt64"), |
| 48 | m_sequence_uint64("mSequenceUint64"), |
| 49 | m_sequence_double("mSequenceDouble"), |
Yves Gerey | 665174f | 2018-06-19 15:03:05 +0200 | [diff] [blame] | 50 | m_sequence_string("mSequenceString") {} |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 51 | |
hbos | fc5e050 | 2016-10-06 02:06:10 -0700 | [diff] [blame] | 52 | RTCTestStats::RTCTestStats(const RTCTestStats& other) |
| 53 | : RTCStats(other.id(), other.timestamp_us()), |
| 54 | m_bool(other.m_bool), |
| 55 | m_int32(other.m_int32), |
| 56 | m_uint32(other.m_uint32), |
| 57 | m_int64(other.m_int64), |
| 58 | m_uint64(other.m_uint64), |
| 59 | m_double(other.m_double), |
| 60 | m_string(other.m_string), |
| 61 | m_sequence_bool(other.m_sequence_bool), |
| 62 | m_sequence_int32(other.m_sequence_int32), |
| 63 | m_sequence_uint32(other.m_sequence_uint32), |
| 64 | m_sequence_int64(other.m_sequence_int64), |
| 65 | m_sequence_uint64(other.m_sequence_uint64), |
| 66 | m_sequence_double(other.m_sequence_double), |
Yves Gerey | 665174f | 2018-06-19 15:03:05 +0200 | [diff] [blame] | 67 | m_sequence_string(other.m_sequence_string) {} |
hbos | fc5e050 | 2016-10-06 02:06:10 -0700 | [diff] [blame] | 68 | |
Yves Gerey | 665174f | 2018-06-19 15:03:05 +0200 | [diff] [blame] | 69 | RTCTestStats::~RTCTestStats() {} |
hbos | fc5e050 | 2016-10-06 02:06:10 -0700 | [diff] [blame] | 70 | |
hbos | 27e177c | 2016-09-19 06:05:56 -0700 | [diff] [blame] | 71 | } // namespace webrtc |