SaxParser Not Working to Extract Larger Strings Android -
i using saxparser parsing xml contains image url long enough. using sax parser storing them in variable. code wrote simple , accurate parse parsing same xml accurately smaller length strings.
which ensure code correctness. saxparser failing in extracting larger strings.
help me out plz
i know doing wrong. though more better answer if post code of yours.
you must storing character string in character reading delegate of parser in string variable. problem .
instead should use string builder , append characters in new buffer extract string xml in character reading delegate .
like this
stringbuilder obj = new stringbuilder(); // in starting tag delegate public void characters (char buf [], int offset, int len) throws saxexception { obj.append(buf); }
this problem occurs many threads can running @ time sometime preempt parsing thread.
hope helps :)
Comments
Post a Comment