zeaster

yichao firstname, zeaster nickname, zhang lastname
  • Home
  • MyBlogger
  • Resume
  • CLI

ZInfo - Information sharing platfrom on Android

Posted by zeaster in April 18th 2008  

ZInfo is finally released for Android Developer Challenge after our many hard working days.
It's
an information sharing platform based on your contacts and location.
The video demo can be found at http://infosword.com/zinfo/video.html.

We gave a presentation about ZInfo on Beijing Open Party - Before the Rain.
It makes me the most excited that I meet a lot of open source followers.
They are very friendly, full of passion, enjoy coding! I learned a lot from them.

Special thanks to cleverpig!
He is so kind and want to sponsor us a server to host ZInfo.
And he understands us fully when we decided to put off releasing publicly recently.

It's so great to meet you guys in the community!

No Comment
under: google, mobile, opensource
Digg it Add to del.icio.us Stumble it add to technorati

most geek wordpress theme

Posted by zeaster in March 16th 2008  
Never been more glad to find such wonderful wordpress theme - wordpress cli

Have a try if you like unix.

No Comment
under: blog
Digg it Add to del.icio.us Stumble it add to technorati

Inconvenienced when using Contact Content Provider on Android

Posted by zeaster in November 28th 2007  

These days, I've been developing an application that reads and writes entries from/into Android Contacts.
Everything goes fine until I need to insert email entry into Android Contact by Contact Content Provider API.

This is how to insert a people or phone entry into contact (people, phones table):
getContentProvider().insert(People.CONTENT_URI, values);
getContentProvider().insert(Phones.CONTENT_URI, values);

That's fine according to
http://code.google.com/android/devel/data/contentproviders.html

However when I insert an email entry into contact (in contact_methods table) using:
ContentURI uri = getContentProvider().insert(ContactMethods.CONTENT_URI, values);

It just returns null, nothing inserted, and nothing shows up on logcat.
Why? the link above says it should be fine!
To find the answer, I post a thread in Google Group:
http://groups.google.com/group/android-developers/browse_thread/thread/9ed4ff7fc1338b7c
However no response.
then I have been diving into build-in Contacts Application for 2 days to find how Google used their own api.
Luckily, I got the key.
see details on my another post:
http://zeaster.com/blog/2007/11/28/how-to-decompile-dex-file-on-android/

You should insert an email like this:
ContentURI uri = People.CONTENT_URI.addId(user_id).addPath("contact_methods");
ContentValues values = ...
uri = getContentResolver().insert(uri, values);

why? I guess Google should provide one same way to insert content.

That's the main inconvenience.
I guess what's even worse is Google does not provide enough docs or log warnings for this tip.
Here are the others:

2.
when insert an email for a not-created-yet user id, It's still inserted successfully.
when the user id created in the future, the user would have the email address.
I guess Google should prevent this happen.
Actually many checks Google need to do.That's really a beta SDK.

3.
The content provider API is not Object-Oriented enough.
I feel it tedious to use.

4.
Maybe this is greedy.
I hope there is API to manipulate database that's similar to ActiveRecord for Rails.
Maybe I will implement one like that if time permits.

3 Comments
under: google, mobile
Digg it Add to del.icio.us Stumble it add to technorati
Newer Entries »
« Older Entries

Search

Most Comments

  • blogsync with gui coming, import your wordpress to blogger (69)
  • blogsync 0.3 released, comments can be imported. (22)
  • A tool that import all posts from wordpress to blogger in python (8)
  • Mac OS X上成功使用dopod 696 wm5.0 连 cmwap上网 (7)
  • blogsync 2.0 released, import your wordpress to blogger from rss xml file or online (5)
  • How to decompile .dex file on Android (4)
  • Inconvenienced when using Contact Content Provider on Android (3)
  • 统一Mac OS X,Windows XP/Vista以及linux的系统时间 (2)
  • Windows XP/Vista vs Mac OS X 软件对比清单 (2)
  • 性能准则之一:在遍历集合前一定要判断集合是否为空 (2)
  • A python script that get posts from wordpress by httplib (1)
  • blogsync FAQ (1)

Recent Comments

  • Naveen chenoli in blogsync with gui coming, import yo…
  • snupijenta in blogsync 0.3 released, comments can…
  • Cristian in blogsync 0.3 released, comments can…
  • Maypu in 说个有趣的事儿,钥匙与ha…
  • Maypu in 看图说话,谈谈adapter,prox…
  • zeaster in blogsync 0.3 released, comments can…
  • the writer in blogsync 0.3 released, comments can…
  • zeaster in Inconvenienced when using Contact C…
  • sshwsfc in Inconvenienced when using Contact C…
  • zeaster - How t… in Inconvenienced when using Contact C…

Categories

    • apple (10)
    • blog (16)
    • english (7)
    • google (8)
    • interview (2)
    • life (11)
    • microsoft (3)
    • mobile (7)
    • opensource (15)
    • tech (8)
    • web (4)

Archives

Meta

    • Log in
    • Entries RSS
    • Comments RSS
    • WordPress.org
Box-Tube Box Modulize WordPress Theme By Dezzain Studio
©2006-2009 zeaster
Wordpress Themes     Valid XHTML    Valid CSS