いつもお世話になっております
ContentResolverにてコンタクトリストを取得する際に以下の2点の実装方法がわからず苦戦しております
①Googleアカウントにのみ紐づいているデータは取得しないようにしたい
②ソートで日本語昇順そのあとに英語昇順で並べたい
何卒よろしくお願い申し上げます
※参考コード追記
Java
1ContentResolver mCResolver = null; 2mCResolver = getContentResolver(); 3 String[] projection = new String[] { ContactsContract.CommonDataKinds.Phone.DISPLAY_NAME }; 4 String order = ContactsContract.CommonDataKinds.Phone.PHONETIC_NAME+ " ASC," + 5 ContactsContract.CommonDataKinds.StructuredName.PHONETIC_FAMILY_NAME + " ASC," + 6 ContactsContract.CommonDataKinds.StructuredName.PHONETIC_GIVEN_NAME + " ASC"; 7 Cursor cursor = mCResolver.query( 8 ContactsContract.Contacts.CONTENT_URI, 9 null, 10 null, 11 null, 12 ContactsContract.Contacts.DISPLAY_NAME + " ASC" 13 );
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2016/12/01 07:02
2016/12/01 08:58
2016/12/02 00:13