If I may intervene.
It seems to me that the OP wants to synchronize contacts using the
sync adapters APIs, and therefore wants to have his own account type,
and raw contacts in this account.

But that means that when the user first starts using this app, this
account will be empty, and will synchronize... nothing.
Instead, they probably expect to synchronize the contacts already on
their phones (in the "local" account, or, more probably, in the gmail
account).

--
BoD


On Jan 19, 9:02 am, Dmitri Plotnikov <[email protected]> wrote:
> I am sorry. I guess I just don't understand the requirements.  I thought you
> were writing a sync adapter.  Sync adapters all deal with their own
> accounts.  Google sync adapter deals with google accounts, exchange adapter
> with exchange accounts and so on.  If you are thinking of writing a sync
> adapter that would handle data already handled by some other sync adapter,
> it is probably a bad idea. The framework is not designed to have multiple
> sync adapters handling the same data: only one syncadapter can take
> advantage of data versioning. This why I suggested that if you are writing a
> sync adapter, you should introduce a new account type. This is how they are
> supposed to work by design.
>
> Cheers,
> Dmitri
> On Jan 18, 2011 5:43 PM, "L0rdAli3n" <[email protected]>
> wrote:
>
> > Thanks for your answer Dmitri!
>
> > Could you explain in few words, how I can use the contacts the user
> > stored on his phone,
> > which in fact all have already an account_type, by introducing my own
> > accout_type?
>
> > On 14 Jan., 16:26, Dmitri Plotnikov <[email protected]> wrote:
> >> I don't fully understand your requirements, but it shouldn't matter what
> >> _other_ data is in the contacts DB.  A sync adapter should only deal with
> >> its own data. Why not introduce a new account type for this purpose?
>
> >> Cheers,
> >> Dmitri
> >> On Jan 14, 2011 5:16 AM, "L0rdAli3n" <[email protected]>
> >> wrote:
>
> >> > Hey,
>
> >> > I'm totally stuck with the ContactsContract-API. Point is that I want
> >> > only mess around with the Contacts saved in the "local" phonebook. But
> >> > it seems that every vendor but its own account_type for those
> >> > contacts.
> >> > And its even worse. The AccountManager isn't even aware of all
> >> > account_types?!?
> >> > For example on my HTC Desire with HTC Sense, the account_type all
> >> > local contacts are saved in is: com.htc.android.pcsc. But when I grab
> >> > a list of all available accounts from the AccountManager: This account
> >> > is not in the list!?
> >> > I also tested it on a Samsung Galaxy. Same here: The AccountManager is
> >> > not aware of the account_type used for local phonebookcontacts.
>
> >> > The whole story is that I wan't to write a app to sync my locale
> >> > phonebook with OpenXchange.
>
> >> > I guess I got that whole new ContactsContract-API wrong, but I don't
> >> > see any other way, then using RawContacts. Due to that I have to care
> >> > about the account_type, which is in fact a total mess.
>
> >> > Hopefully someone can point me in the right direction. Every hint is
> >> > highly appreciated.
>
> >> > --
> >> > You received this message because you are subscribed to the Google
> >> > Groups "Android Developers" group.
> >> > To post to this group, send email to
>
> [email protected]>> > To unsubscribe from this group, send 
> email to
> >> > [email protected]<android-developers%[email protected]>
>
> <android-developers%[email protected]<android-developers%[email protected]>
>
>
>
> >> > 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 [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]<android-developers%[email protected]>
> > 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 [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to