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

Side by Side Diff: webrtc/stream.h

Issue 1226123005: Define Stream base classes (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Code review follow-up Created 5 years, 5 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
« no previous file with comments | « webrtc/call.h ('k') | webrtc/video/audio_receive_stream.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 /*
2 * Copyright (c) 2015 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 #ifndef WEBRTC_STREAM_H_
11 #define WEBRTC_STREAM_H_
12
13 #include "webrtc/common_types.h"
14
15 namespace webrtc {
16
17 enum NetworkState {
18 kNetworkUp,
19 kNetworkDown,
20 };
21
22 // Common base class for streams.
23 class Stream {
24 public:
25 virtual void Start() = 0;
26 virtual void Stop() = 0;
stefan-webrtc 2015/07/15 11:48:45 What are Start and Stop supposed to be used for? I
27 virtual void SignalNetworkState(NetworkState state) = 0;
28 virtual bool DeliverRtcp(const uint8_t* packet, size_t length) = 0;
29
30 protected:
31 virtual ~Stream() {}
32 };
33
34 // Common base class for receive streams.
35 class ReceiveStream : public Stream {
36 public:
37 virtual bool DeliverRtp(const uint8_t* packet, size_t length) = 0;
38 };
39
40 // Common base class for send streams.
41 // A tag class that represents send stream concept and serves as a placeholder
42 // for future functionality.
43 class SendStream : public Stream {};
44
45 } // namespace webrtc
46
47 #endif // WEBRTC_STREAM_H_
OLDNEW
« no previous file with comments | « webrtc/call.h ('k') | webrtc/video/audio_receive_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698