xref: /aosp_15_r20/external/webrtc/pc/legacy_stats_collector_interface.h (revision d9f758449e529ab9291ac668be2861e7a55c2422)
1 /*
2  *  Copyright 2020 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 
11 // This file contains an interface for the (obsolete) StatsCollector class that
12 // is used by compilation units that do not wish to depend on the StatsCollector
13 // implementation.
14 
15 #ifndef PC_LEGACY_STATS_COLLECTOR_INTERFACE_H_
16 #define PC_LEGACY_STATS_COLLECTOR_INTERFACE_H_
17 
18 #include <stdint.h>
19 
20 #include "api/legacy_stats_types.h"
21 #include "api/media_stream_interface.h"
22 
23 namespace webrtc {
24 
25 class LegacyStatsCollectorInterface {
26  public:
~LegacyStatsCollectorInterface()27   virtual ~LegacyStatsCollectorInterface() {}
28 
29   // Adds a local audio track that is used for getting some voice statistics.
30   virtual void AddLocalAudioTrack(AudioTrackInterface* audio_track,
31                                   uint32_t ssrc) = 0;
32 
33   // Removes a local audio tracks that is used for getting some voice
34   // statistics.
35   virtual void RemoveLocalAudioTrack(AudioTrackInterface* audio_track,
36                                      uint32_t ssrc) = 0;
37   virtual void GetStats(MediaStreamTrackInterface* track,
38                         StatsReports* reports) = 0;
39 };
40 
41 }  // namespace webrtc
42 
43 #endif  // PC_LEGACY_STATS_COLLECTOR_INTERFACE_H_
44