OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2013 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 // This file contains Macros for creating proxies for webrtc MediaStream and | 11 // This file contains Macros for creating proxies for webrtc MediaStream and |
12 // PeerConnection classes. | 12 // PeerConnection classes. |
| 13 // TODO(deadbeef): Move this to pc/; this is part of the implementation. |
13 | 14 |
14 // | 15 // |
15 // Example usage: | 16 // Example usage: |
16 // | 17 // |
17 // class TestInterface : public rtc::RefCountInterface { | 18 // class TestInterface : public rtc::RefCountInterface { |
18 // public: | 19 // public: |
19 // std::string FooA() = 0; | 20 // std::string FooA() = 0; |
20 // std::string FooB(bool arg1) const = 0; | 21 // std::string FooB(bool arg1) const = 0; |
21 // std::string FooC(bool arg1) = 0; | 22 // std::string FooC(bool arg1) = 0; |
22 // }; | 23 // }; |
(...skipping 527 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
550 #define PROXY_WORKER_CONSTMETHOD2(r, method, t1, t2) \ | 551 #define PROXY_WORKER_CONSTMETHOD2(r, method, t1, t2) \ |
551 r method(t1 a1, t2 a2) const override { \ | 552 r method(t1 a1, t2 a2) const override { \ |
552 ConstMethodCall2<C, r, t1, t2> call(c_.get(), &C::method, std::move(a1), \ | 553 ConstMethodCall2<C, r, t1, t2> call(c_.get(), &C::method, std::move(a1), \ |
553 std::move(a2)); \ | 554 std::move(a2)); \ |
554 return call.Marshal(RTC_FROM_HERE, worker_thread_); \ | 555 return call.Marshal(RTC_FROM_HERE, worker_thread_); \ |
555 } | 556 } |
556 | 557 |
557 } // namespace webrtc | 558 } // namespace webrtc |
558 | 559 |
559 #endif // WEBRTC_API_PROXY_H_ | 560 #endif // WEBRTC_API_PROXY_H_ |
OLD | NEW |