Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(118)

Side by Side Diff: webrtc/logging/rtc_event_log/rtc_event_log.h

Issue 2854123003: Build WebRTC with data channel only. (Closed)
Patch Set: Fix the issues. Make it ready for another round of review. Add a test. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 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 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 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
11 #ifndef WEBRTC_LOGGING_RTC_EVENT_LOG_RTC_EVENT_LOG_H_ 11 #ifndef WEBRTC_LOGGING_RTC_EVENT_LOG_RTC_EVENT_LOG_H_
12 #define WEBRTC_LOGGING_RTC_EVENT_LOG_RTC_EVENT_LOG_H_ 12 #define WEBRTC_LOGGING_RTC_EVENT_LOG_RTC_EVENT_LOG_H_
13 13
14 #include <memory> 14 #include <memory>
15 #include <string> 15 #include <string>
16 #include <vector> 16 #include <vector>
17 17
18 #include "webrtc/base/logging.h"
18 #include "webrtc/base/platform_file.h" 19 #include "webrtc/base/platform_file.h"
19 #include "webrtc/call/audio_receive_stream.h" 20 #include "webrtc/call/audio_receive_stream.h"
20 #include "webrtc/call/audio_send_stream.h" 21 #include "webrtc/call/audio_send_stream.h"
21 #include "webrtc/video_receive_stream.h" 22 #include "webrtc/video_receive_stream.h"
22 #include "webrtc/video_send_stream.h" 23 #include "webrtc/video_send_stream.h"
23 24
24 namespace webrtc { 25 namespace webrtc {
25 26
26 // Forward declaration of storage class that is automatically generated from 27 // Forward declaration of storage class that is automatically generated from
27 // the protobuf file. 28 // the protobuf file.
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 }; 189 };
189 190
190 // No-op implementation is used if flag is not set, or in tests. 191 // No-op implementation is used if flag is not set, or in tests.
191 class RtcEventLogNullImpl final : public RtcEventLog { 192 class RtcEventLogNullImpl final : public RtcEventLog {
192 public: 193 public:
193 bool StartLogging(const std::string& file_name, 194 bool StartLogging(const std::string& file_name,
194 int64_t max_size_bytes) override { 195 int64_t max_size_bytes) override {
195 return false; 196 return false;
196 } 197 }
197 bool StartLogging(rtc::PlatformFile platform_file, 198 bool StartLogging(rtc::PlatformFile platform_file,
198 int64_t max_size_bytes) override; 199 int64_t max_size_bytes) override {
200 // The platform_file is open and needs to be closed.
201 if (!rtc::ClosePlatformFile(platform_file)) {
202 LOG(LS_ERROR) << "Can't close file.";
203 }
204 return false;
205 }
199 void StopLogging() override {} 206 void StopLogging() override {}
200 void LogVideoReceiveStreamConfig( 207 void LogVideoReceiveStreamConfig(
201 const rtclog::StreamConfig& config) override {} 208 const rtclog::StreamConfig& config) override {}
202 void LogVideoSendStreamConfig(const rtclog::StreamConfig& config) override {} 209 void LogVideoSendStreamConfig(const rtclog::StreamConfig& config) override {}
203 void LogAudioReceiveStreamConfig( 210 void LogAudioReceiveStreamConfig(
204 const rtclog::StreamConfig& config) override {} 211 const rtclog::StreamConfig& config) override {}
205 void LogAudioSendStreamConfig(const rtclog::StreamConfig& config) override {} 212 void LogAudioSendStreamConfig(const rtclog::StreamConfig& config) override {}
206 void LogRtpHeader(PacketDirection direction, 213 void LogRtpHeader(PacketDirection direction,
207 MediaType media_type, 214 MediaType media_type,
208 const uint8_t* header, 215 const uint8_t* header,
(...skipping 20 matching lines...) Expand all
229 int min_probes, 236 int min_probes,
230 int min_bytes) override{}; 237 int min_bytes) override{};
231 void LogProbeResultSuccess(int id, int bitrate_bps) override{}; 238 void LogProbeResultSuccess(int id, int bitrate_bps) override{};
232 void LogProbeResultFailure(int id, 239 void LogProbeResultFailure(int id,
233 ProbeFailureReason failure_reason) override{}; 240 ProbeFailureReason failure_reason) override{};
234 }; 241 };
235 242
236 } // namespace webrtc 243 } // namespace webrtc
237 244
238 #endif // WEBRTC_LOGGING_RTC_EVENT_LOG_RTC_EVENT_LOG_H_ 245 #endif // WEBRTC_LOGGING_RTC_EVENT_LOG_RTC_EVENT_LOG_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698