Zoullou wrote: > I currently building an adnroid apps that retrive data from a distant > Web service and i search an efficient way to bind data form XML to > ListView. > I already use CursorAdapter and i search on the web for an > "XmlAdapter". I read on Google IO topic "Coding for Life -- Battery > Life, That Is" (http://code.google.com/events/io/sessions/ > CodingLifeBatteryLife.html) that is more efficient to use "stream > parser" instead of "tree parser" but i don't find the way to build a > class that implement ListAdapter because of stream parser can't > navigate backward so i don't understand how implement method that use > "position" parameter (How retrive data before curent XML Parser > position ???). > > I don't find solution for this problem on the web after make search > (maybe a don't make good search), so could you give me the way to > solve my problem ?
Have the parser pour the data into a MatrixCursor, and use a CursorAdapter. Or, have the parser pour the data into model objects of your creation, and put those in an ArrayList, and use an ArrayAdapter. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Development Wiki: http://wiki.andmob.org --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---