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

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

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

    小菜毛毛技術(shù)分享

    與大家共同成長

      BlogJava :: 首頁 :: 聯(lián)系 :: 聚合  :: 管理
      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
    主站蜘蛛池模板: 亚洲日产乱码一二三区别| 亚洲成a人片在线观看久| 4虎永免费最新永久免费地址| 男人都懂www深夜免费网站| A片在线免费观看| 花蝴蝶免费视频在线观看高清版| 国产伦精品一区二区免费| 一级做a爰片性色毛片免费网站| 一区二区免费在线观看| 免费看美女午夜大片| 一级做a爰片久久毛片免费看| 国产裸体美女永久免费无遮挡| 福利免费在线观看| 免费看无码特级毛片| 久久w5ww成w人免费| 色片在线免费观看| 成人免费看吃奶视频网站| 国产精品免费看香蕉| 亚洲成av人片不卡无码久久| 国产亚洲精品免费视频播放| 亚洲精品乱码久久久久久按摩 | 免费特级黄毛片在线成人观看 | 久久精品一区二区免费看| 18禁男女爽爽爽午夜网站免费| 亚洲高清中文字幕免费| 成人性生活免费视频| 免费国产精品视频| 亚洲精品成人网站在线观看| 亚洲国产精品人久久| 亚洲最大福利视频| 日韩精品无码永久免费网站| 国产午夜精品免费一区二区三区 | 大地资源在线资源免费观看| 57pao国产成视频免费播放| 无码高潮少妇毛多水多水免费| 免费在线黄色网址| 亚洲国产成人一区二区三区| 亚洲一区二区三区精品视频| 粉色视频成年免费人15次| 国产免费无码AV片在线观看不卡| 大学生一级毛片免费看|