| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  *  Copyright 2017 The WebRTC Project Authors. All rights reserved. | 2  *  Copyright 2017 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_P2P_BASE_FAKEPACKETTRANSPORT_H_ | 11 #ifndef WEBRTC_P2P_BASE_FAKEPACKETTRANSPORT_H_ | 
| 12 #define WEBRTC_P2P_BASE_FAKEPACKETTRANSPORT_H_ | 12 #define WEBRTC_P2P_BASE_FAKEPACKETTRANSPORT_H_ | 
| 13 | 13 | 
| 14 #include <string> | 14 #include <string> | 
| 15 | 15 | 
| 16 #include "webrtc/api/ortc/packettransportinterface.h" | 16 #include "webrtc/api/ortc/packettransportinterface.h" | 
| 17 #include "webrtc/base/asyncinvoker.h" |  | 
| 18 #include "webrtc/base/copyonwritebuffer.h" |  | 
| 19 #include "webrtc/p2p/base/packettransportinternal.h" | 17 #include "webrtc/p2p/base/packettransportinternal.h" | 
|  | 18 #include "webrtc/rtc_base/asyncinvoker.h" | 
|  | 19 #include "webrtc/rtc_base/copyonwritebuffer.h" | 
| 20 | 20 | 
| 21 namespace rtc { | 21 namespace rtc { | 
| 22 | 22 | 
| 23 // Used to simulate a packet-based transport. | 23 // Used to simulate a packet-based transport. | 
| 24 class FakePacketTransport : public PacketTransportInternal { | 24 class FakePacketTransport : public PacketTransportInternal { | 
| 25  public: | 25  public: | 
| 26   explicit FakePacketTransport(const std::string& debug_name) | 26   explicit FakePacketTransport(const std::string& debug_name) | 
| 27       : debug_name_(debug_name) {} | 27       : debug_name_(debug_name) {} | 
| 28   ~FakePacketTransport() override { | 28   ~FakePacketTransport() override { | 
| 29     if (dest_ && dest_->dest_ == this) { | 29     if (dest_ && dest_->dest_ == this) { | 
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 118   FakePacketTransport* dest_ = nullptr; | 118   FakePacketTransport* dest_ = nullptr; | 
| 119   bool async_ = false; | 119   bool async_ = false; | 
| 120   int async_delay_ms_ = 0; | 120   int async_delay_ms_ = 0; | 
| 121   bool writable_ = false; | 121   bool writable_ = false; | 
| 122   bool receiving_ = false; | 122   bool receiving_ = false; | 
| 123 }; | 123 }; | 
| 124 | 124 | 
| 125 }  // namespace rtc | 125 }  // namespace rtc | 
| 126 | 126 | 
| 127 #endif  // WEBRTC_P2P_BASE_FAKEPACKETTRANSPORT_H_ | 127 #endif  // WEBRTC_P2P_BASE_FAKEPACKETTRANSPORT_H_ | 
| OLD | NEW | 
|---|