I did so. The Stream now gets live altered so what was before: ... ="&ref;" now becomes ... ="&ref;"
The funny thing is what ends up in the SAX-Parsers parameter is just : "ref;". Evertything between AMPERSANDS and SEMICOLONS gets removed by the SAX-Parser... o_O Or it gets magically resolved with an empty string ;) Best Regards, Nicolas On 16 Jan., 10:55, Daniel Janev <[email protected]> wrote: > So, if you want to use the SAXParser you can write a wrapper of the > stream it uses and to change any & with & :) Another possible > solution is to find parser which can parse correct all data with &. > > > > plusminus wrote: > > I can't (properly) do so, because I do not serve the data. > > > Best Regards, > > plusminus > > > On 16 Jan., 08:41, Daniel Janev <[email protected]> wrote: > >> Hi Guys, > > >> Why don't you try to escape the &? I've had same problems with kXML > >> parser for MIDP and escaping the "&" with & everything works fine. > > >> plusminus wrote: > >>> The qName <--> localName difference to SAX in Desktop-Java also > >>> appies. > >>> I'll definitely keep you up if I have a solution. > >>> This is killing me =( > >>> Best Regards, > >>> Nicolas > >>> On 16 Jan., 05:39, "[email protected]" > >>> <[email protected]> wrote: > >>>> Hi, > >>>> The implementation of SAXParser seems to encounter problems when it > >>>> attempts to parse anything with '&'. > >>>> Have a look at those threads, if you haven't done so already: > >>>>http://groups.google.com/group/android-developers/browse_thread/threa... > >>>>http://groups.google.com/group/android-developers/browse_thread/threa... > >>>> If you manage to get the correct value, pls update the thread! > >>>> On Jan 16, 5:23 am, plusminus <[email protected]> wrote: > >>>>> Hi all, > >>>>> I have a problem with the SAX-Parser and getting attributes which are > >>>>> references... > >>>>> ############ > >>>>> <item id="2833670" generation_time="2009-01-15T21:09:09+0" > >>>>> version_number="4" start_time="2009-01-15T19:45:36+0" > >>>>> stop_time="2009-01-16T21:57:32+0" factor="&rtm31_4;"> > >>>>> ############ > >>>>> in startElement(...) attributes correctly indicates the existence of 6 > >>>>> elements > >>>>> I can get all attributes using i.e. final String startTime = > >>>>> attributes.getValue("", "start_time"); > >>>>> except the last one ( factor="&rtm31_4;" ) > >>>>> Where: > >>>>> ############ > >>>>> attributes.getValue("factor"); > >>>>> // or > >>>>> attributes.getValue("", "factor"); > >>>>> ############ > >>>>> always returns "" (empty string) > >>>>> it seems like the Entity-Reference is not being resolved =( > >>>>> If I set an EntityResolver: > >>>>> ############ > >>>>> myXMLReader.setEntityResolver(new EntityResolver(){ > >>>>> public InputSource resolveEntity(...) { > >>>>> }} > >>>>> ############ > >>>>> It NEVER gets called :( > >>>>> The same code worked in Desktop-Java, all Entities were resolved via > >>>>> the EntityResolver. > >>>>> Any ideas? I've spent half a day on this issue alreade =( > >>>>> Best Regards, > >>>>> plusminus > >> -- > > >> Best Regards, > >> Daniel > >> --------------------------------------------------------------- > >> Daniel Janev · Department Manager/Core Platform and Smart Home > >> ProSyst Software GmbH > >> 1606 Sofia, Bulgaria · Vladajska Str. 48 > >> Tel. +359 (0)2 952 35 81/109 · Fax +359 (0)2 953 26 17 > >> Mobile Phone +359 (0)888 678 670http://www.prosyst.com·[email protected] > >> --------------------------------------------------------------- > >> stay in touch with your product. > >> --------------------------------------------------------------- > > -- > > Best Regards, > Daniel > --------------------------------------------------------------- > Daniel Janev · Department Manager/Core Platform and Smart Home > ProSyst Software GmbH > 1606 Sofia, Bulgaria · Vladajska Str. 48 > Tel. +359 (0)2 952 35 81/109 · Fax +359 (0)2 953 26 17 > Mobile Phone +359 (0)888 678 670http://www.prosyst.com· [email protected] > --------------------------------------------------------------- > stay in touch with your product. > --------------------------------------------------------------- --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---

