| OLD | NEW |
| 1 /* | 1 // TODO(pthatcher): Remove this file once Chrome's build files no |
| 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. | 2 // longer refer to it. |
| 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 #ifndef WEBRTC_P2P_BASE_RAWTRANSPORT_H_ | |
| 12 #define WEBRTC_P2P_BASE_RAWTRANSPORT_H_ | |
| 13 | |
| 14 #include <string> | |
| 15 #include "webrtc/p2p/base/transport.h" | |
| 16 | |
| 17 #if defined(FEATURE_ENABLE_PSTN) | |
| 18 namespace cricket { | |
| 19 | |
| 20 // Implements a transport that only sends raw packets, no STUN. As a result, | |
| 21 // it cannot do pings to determine connectivity, so it only uses a single port | |
| 22 // that it thinks will work. | |
| 23 class RawTransport : public Transport { | |
| 24 public: | |
| 25 RawTransport(rtc::Thread* signaling_thread, | |
| 26 rtc::Thread* worker_thread, | |
| 27 const std::string& content_name, | |
| 28 PortAllocator* allocator); | |
| 29 virtual ~RawTransport(); | |
| 30 | |
| 31 protected: | |
| 32 // Creates and destroys raw channels. | |
| 33 virtual TransportChannelImpl* CreateTransportChannel(int component); | |
| 34 virtual void DestroyTransportChannel(TransportChannelImpl* channel); | |
| 35 | |
| 36 private: | |
| 37 friend class RawTransportChannel; // For ParseAddress. | |
| 38 | |
| 39 DISALLOW_COPY_AND_ASSIGN(RawTransport); | |
| 40 }; | |
| 41 | |
| 42 } // namespace cricket | |
| 43 | |
| 44 #endif // defined(FEATURE_ENABLE_PSTN) | |
| 45 | |
| 46 #endif // WEBRTC_P2P_BASE_RAWTRANSPORT_H_ | |
| OLD | NEW |