本文介绍了有可能得到与QUOT拥有者QUOT;联系Android的信息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我一直没能找到这个一个直接的答案。谁能告诉我,如果有可能拿到手机的用户的联系人信息中的Android应用程序?
I haven't been able to find a straight answer on this. Can anyone tell me if it's possible to get the contact info of the phone's owner in an Android App?
推荐答案
因此,答案是技术上没有。我发现,到目前为止,获得业主的数据的唯一方法就是通过客户经理。下面是如何使用它的一个例子:
So the answer is technically no. The only way I've found so far to get owner's data is through the account manager. Here's an example of how to use it:
final AccountManager manager = AccountManager.get(this);
final Account[] accounts = manager.getAccountsByType("com.google");
final int size = accounts.length;
String[] names = new String[size];
for (int i = 0; i < size; i++) {
names[i] = accounts[i].name;
}
有关详细信息,请参阅:的http:// code.google.com / P /谷歌API的Java的客户端/维基/ AndroidAccountManager
For more info see: http://code.google.com/p/google-api-java-client/wiki/AndroidAccountManager
这篇关于有可能得到与QUOT拥有者QUOT;联系Android的信息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!