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

Side by Side Diff: remoting/client/jni/jni_client.h

Issue 2629593003: [Chromoting.com] Make Android telemetry report host version/os/os version (Closed)
Patch Set: PTAL Point Created 3 years, 11 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef REMOTING_CLIENT_JNI_JNI_CLIENT_H_ 5 #ifndef REMOTING_CLIENT_JNI_JNI_CLIENT_H_
6 #define REMOTING_CLIENT_JNI_JNI_CLIENT_H_ 6 #define REMOTING_CLIENT_JNI_JNI_CLIENT_H_
7 7
8 #include <jni.h> 8 #include <jni.h>
9 9
10 #include "base/android/scoped_java_ref.h" 10 #include "base/android/scoped_java_ref.h"
(...skipping 22 matching lines...) Expand all
33 // pair-based authentication, leave |pairing_id| and |pairing_secret| as 33 // pair-based authentication, leave |pairing_id| and |pairing_secret| as
34 // empty strings. 34 // empty strings.
35 void ConnectToHost(const std::string& username, 35 void ConnectToHost(const std::string& username,
36 const std::string& auth_token, 36 const std::string& auth_token,
37 const std::string& host_jid, 37 const std::string& host_jid,
38 const std::string& host_id, 38 const std::string& host_id,
39 const std::string& host_pubkey, 39 const std::string& host_pubkey,
40 const std::string& pairing_id, 40 const std::string& pairing_id,
41 const std::string& pairing_secret, 41 const std::string& pairing_secret,
42 const std::string& capabilities, 42 const std::string& capabilities,
43 const std::string& flags); 43 const std::string& flags,
44 const std::string& host_version,
45 const std::string& host_os,
46 const std::string& host_os_version);
44 47
45 // Terminates any ongoing connection attempt and cleans up by nullifying 48 // Terminates any ongoing connection attempt and cleans up by nullifying
46 // |session_|. This is a no-op unless |session| is currently non-null. 49 // |session_|. This is a no-op unless |session| is currently non-null.
47 void DisconnectFromHost(); 50 void DisconnectFromHost();
48 51
49 // Notifies Java code of the current connection status. Call on UI thread. 52 // Notifies Java code of the current connection status. Call on UI thread.
50 void OnConnectionState(protocol::ConnectionToHost::State state, 53 void OnConnectionState(protocol::ConnectionToHost::State state,
51 protocol::ErrorCode error); 54 protocol::ErrorCode error);
52 55
53 // Pops up a dialog box asking the user to enter a PIN. Call on UI thread. 56 // Pops up a dialog box asking the user to enter a PIN. Call on UI thread.
(...skipping 26 matching lines...) Expand all
80 void Connect(JNIEnv* env, 83 void Connect(JNIEnv* env,
81 const base::android::JavaParamRef<jobject>& caller, 84 const base::android::JavaParamRef<jobject>& caller,
82 const base::android::JavaParamRef<jstring>& username, 85 const base::android::JavaParamRef<jstring>& username,
83 const base::android::JavaParamRef<jstring>& authToken, 86 const base::android::JavaParamRef<jstring>& authToken,
84 const base::android::JavaParamRef<jstring>& hostJid, 87 const base::android::JavaParamRef<jstring>& hostJid,
85 const base::android::JavaParamRef<jstring>& hostId, 88 const base::android::JavaParamRef<jstring>& hostId,
86 const base::android::JavaParamRef<jstring>& hostPubkey, 89 const base::android::JavaParamRef<jstring>& hostPubkey,
87 const base::android::JavaParamRef<jstring>& pairId, 90 const base::android::JavaParamRef<jstring>& pairId,
88 const base::android::JavaParamRef<jstring>& pairSecret, 91 const base::android::JavaParamRef<jstring>& pairSecret,
89 const base::android::JavaParamRef<jstring>& capabilities, 92 const base::android::JavaParamRef<jstring>& capabilities,
90 const base::android::JavaParamRef<jstring>& flags); 93 const base::android::JavaParamRef<jstring>& flags,
94 const base::android::JavaParamRef<jstring>& host_version,
95 const base::android::JavaParamRef<jstring>& host_os,
96 const base::android::JavaParamRef<jstring>& host_os_version);
91 97
92 void Disconnect(JNIEnv* env, 98 void Disconnect(JNIEnv* env,
93 const base::android::JavaParamRef<jobject>& caller); 99 const base::android::JavaParamRef<jobject>& caller);
94 100
95 void AuthenticationResponse( 101 void AuthenticationResponse(
96 JNIEnv* env, 102 JNIEnv* env,
97 const base::android::JavaParamRef<jobject>& caller, 103 const base::android::JavaParamRef<jobject>& caller,
98 const base::android::JavaParamRef<jstring>& pin, 104 const base::android::JavaParamRef<jstring>& pin,
99 jboolean createPair, 105 jboolean createPair,
100 const base::android::JavaParamRef<jstring>& deviceName); 106 const base::android::JavaParamRef<jstring>& deviceName);
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 // Holds pointer for the UI thread. 173 // Holds pointer for the UI thread.
168 base::WeakPtr<JniClient> weak_ptr_; 174 base::WeakPtr<JniClient> weak_ptr_;
169 base::WeakPtrFactory<JniClient> weak_factory_; 175 base::WeakPtrFactory<JniClient> weak_factory_;
170 176
171 DISALLOW_COPY_AND_ASSIGN(JniClient); 177 DISALLOW_COPY_AND_ASSIGN(JniClient);
172 }; 178 };
173 179
174 } // namespace remoting 180 } // namespace remoting
175 181
176 #endif // REMOTING_CLIENT_JNI_JNI_CLIENT_H_ 182 #endif // REMOTING_CLIENT_JNI_JNI_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698