On Fri, Sep 2, 2011 at 9:57 PM, bob <[email protected]> wrote: > I'm trying to load a 3.6MB XML file like this: > > URL url = new URL(play_url); > DocumentBuilderFactory dbf = > DocumentBuilderFactory.newInstance(); > DocumentBuilder db = dbf.newDocumentBuilder(); > Document doc = db.parse(new > InputSource(url.openStream())); >
It may be a 3.6MB file, but in memory it's probably much larger due to the Document bloat. Use PullParser or SaxParser and process the data as you go. ------------------------------------------------------------------------------------------------- TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago transit tracking app for Android-powered devices -- 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

