Artem Titov | 70899e0 | 2018-03-22 13:34:24 +0100 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2018 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 | #include "sdk/android/native_api/peerconnection/peerconnectionfactory.h" |
| 11 | |
| 12 | #include <jni.h> |
| 13 | |
| 14 | #include <memory> |
| 15 | #include <utility> |
| 16 | |
| 17 | #include "sdk/android/src/jni/pc/peerconnectionfactory.h" |
| 18 | |
| 19 | namespace webrtc { |
| 20 | |
| 21 | jobject NativeToJavaPeerConnectionFactory( |
| 22 | JNIEnv* jni, |
| 23 | rtc::scoped_refptr<webrtc::PeerConnectionFactoryInterface> pcf, |
| 24 | std::unique_ptr<rtc::Thread> network_thread, |
| 25 | std::unique_ptr<rtc::Thread> worker_thread, |
| 26 | std::unique_ptr<rtc::Thread> signaling_thread, |
| 27 | rtc::NetworkMonitorFactory* network_monitor_factory) { |
| 28 | return webrtc::jni::NativeToJavaPeerConnectionFactory( |
| 29 | jni, pcf, std::move(network_thread), std::move(worker_thread), |
| 30 | std::move(signaling_thread), network_monitor_factory); |
| 31 | } |
| 32 | |
| 33 | } // namespace webrtc |