<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    小菜毛毛技術分享

    與大家共同成長

      BlogJava :: 首頁 :: 聯系 :: 聚合  :: 管理
      164 Posts :: 141 Stories :: 94 Comments :: 0 Trackbacks
    1. String[] projection = new String[] {  
    2. People._ID,  
    3. People.NAME,  
    4. People.NUMBER,  
    5. };  
    6.   
    7. // Get the base URI for People table in Contacts content provider.  
    8. // which is: content://contacts/people/  
    9. Uri contactUri = People.CONTENT_URI;  
    10.   
    11. // Best way to retrieve a query; returns a managed query.  
    12. Cursor peopleCursor = managedQuery (contactUri,  
    13. projection, //Which columns to return.  
    14. null, // WHERE clause--we won't specify.  
    15. null, // Selection Args??  
    16. People.DEFAULT_SORT_ORDER); // Order-by name  
    17.   
    18. // go to the beginning of the list  
    19. peopleCursor.moveToFirst();  
    20.   
    21.   
    22. // So, here we have a contact. We need to get the contact ID (_id) then  
    23. // build the Uri to get the phones section of that user's record  
    24. // which is a subdirectory of a contact record  
    25.   
    26. long personId = peopleCursor.getLong(peopleCursor.getColumnIndex("_id"));  
    27.   
    28. Uri personUri = ContentUris.withAppendedId(contactUri, personId );  
    29.   
    30. // So now the URL looks like: content://contacts/people/_id(where the actual id of the record is here)  
    31. Uri phoneUri=  
    32. Uri.withAppendedPath(personUri, Contacts.People.Phones.CONTENT_DIRECTORY);  
    33.   
    34. // Now the URL looks like: content://contacts/people/_id/phones (where phones is literally "phones")  
    35.   
    36. // Now get all the phone numbers for this contact  
    37. Cursor phonesCursor = managedQuery(phoneUri,  
    38. null,  
    39. null,  
    40. null,  
    41. Phones.DEFAULT_SORT_ORDER);  
    42.   
    43. // We now have a cursor for all the phone numbers for that User ID  
    44. // go to the beginning of the phone list.  
    45. phonesCursor.moveToFirst();   
    posted on 2010-12-17 17:45 小菜毛毛 閱讀(1050) 評論(0)  編輯  收藏 所屬分類: andriod
    主站蜘蛛池模板: 亚洲成AV人片在WWW| 亚洲国产精品久久人人爱| 国产一区二区三区亚洲综合| 三年片在线观看免费大全| 亚洲另类春色国产精品| 国产精彩免费视频| 亚洲色欲色欲www| 好爽…又高潮了免费毛片| 亚洲成AV人影片在线观看| 免费大片黄手机在线观看 | 久久久亚洲裙底偷窥综合| 亚洲三级在线免费观看| 激情亚洲一区国产精品| 免费观看毛片视频| 深夜久久AAAAA级毛片免费看| 亚洲精品无码专区久久同性男| 国产精品福利在线观看免费不卡| 亚洲人成影院在线无码按摩店| a级毛片无码免费真人久久| 久久精品国产亚洲av高清漫画| 一色屋成人免费精品网站| 亚洲欧美aⅴ在线资源| 亚洲精品第一国产综合精品99 | 久久久久国产精品免费看| 亚洲无删减国产精品一区| 成年在线观看免费人视频草莓| 久久久久久亚洲av无码蜜芽| 自拍偷自拍亚洲精品被多人伦好爽 | 亚洲经典在线中文字幕| 免费观看的毛片手机视频| 成人免费777777被爆出| 亚洲高清无在码在线电影不卡| 日韩免费观看一级毛片看看 | 57pao国产成永久免费视频| 亚洲一区二区三区国产精华液| 亚洲va中文字幕无码| 精品一区二区三区免费毛片爱| 亚洲av无码专区亚洲av不卡| 亚洲精品成人片在线观看精品字幕 | 久久久久国色AV免费观看性色| 国产精品午夜免费观看网站|