查询系统分组信息

来源:互联网 发布:乐视mac客户端 编辑:程序博客网 时间:2024/04/30 00:37

查找系统中的分组信息,比较简单,写下来分享一下~ 


Cursor cursor = getContentResolver().query(  

        ContactsContract.Groups.CONTENT_URI, null,  
                null, null, null);  
        while (cursor.moveToNext()) {  
  
            String title = cursor  
                    .getString(cursor  
                            .getColumnIndex(ContactsContract.Groups.TITLE));  
            Log.v("GROUP TITLE", title);  
        }
  
           
        cursor.close();  
原创粉丝点击