Thank you - I am going to start in the suggested direction. (I really
appreciate you taking time)

On Nov 7, 12:00 pm, Dmitri Plotnikov <dplotni...@google.com> wrote:
> Hi Ravi,
>
> It is important to understand that when you read any Data row, the
> corresponding Contact data is joined with it, so when you read an email
> address or a phone number you also have access to DISPLAY_NAME and other
> stuff like STARRED as well as the latest social status update and
> availability in chat.
>
> 1. resolver.query(Phone.CONTENT_URI, new String[]{Phone.CONTACT_ID,
> Phone.DISPLAY_NAME, Phone.NUMBER, Phone.TYPE},...)
>
> 2. The best idea here is to use phone lookup, because it is aware of things
> like +1(555)5554444 and 555-555-4444 being the same number:
> Uri uri = Uri.withAppendedPath(PhoneLookup.CONTENT_FILTER_URI,
> Uri.encode(phoneNumber))
> resolver.query(uri, new String[]{PhoneLookup.DISPLAY_NAME,...
>
> 3. This is just general Data.CONTENT_URI query.  You can add a filter like
> Data.MIMETYPE + " IN('" + Email.CONTENT_ITEM_TYPE + "',... to your selection
> or just read all data, iterate and pick out the items with the MIMETYPE you
> want.
>
> I hope this helps,
> - Dmitri
>
> On Sat, Nov 7, 2009 at 6:15 AM, Ravi <textlo...@gmail.com> wrote:
> > Please post if you have any. I am searching all across to understand
> > the new API but not much to go by:
>
> > 1: Get a cursor that gives all:  - ContactID, Name, Phone Number,
> > Phone Type (or some other way to get this information)
> > 2: Get name by phone number
> > 3: Get a cursor that gives: contact_id, (organization, address, im,
> > email), corrosponding type i
>
> > - I am trying to find similar functionality as contacts and
> > contact_methods that were there in till 1.6. If you have any example
> > or pointers would be appreciated. PS: API documentation is of not much
> > help.
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com>
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to