|
bugreport kXML-RPC: msg#00039java.enhydra.general
Hello once more, i continued evaluating kXML-RPC and found out that the parsing of responses containing arrays would not work but will throw parsing exceptions. So I had a look into the sourcecode. Obviously the "data" element of the array is not parsed: <array><data><value>.</value></data></array>. So I added 4 lines to the parseArray function that consumes the data start and end elements and skips all whitespaces. The function now looks like the following : == Vector parseArray() throws IOException { Vector v = new Vector(); parser.skip(); //BUGFIX hm// we have to consume the data element before we can access the value elements parser.read(Xml.START_TAG, "", "data"); parser.skip(); while (parser.peek().getType() != Xml.END_TAG) { v.addElement(parseValue()); // parse this element value parser.skip(); } //end while( parser.peek().getType() != Xml.END_TAG ) //BUGFIX hm // we have to eat the closing element of the data tag before we can proceed parser.read(Xml.END_TAG, "", "data"); parser.skip(); return v; } //end parseArray() == I suggest including those changes into the next release. Best Regards Heiko Milke!
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | bugreport kXML-RPC, Heiko Milke |
|---|---|
| Next by Date: | usage of ksoap, Micha Eigner |
| Previous by Thread: | bugreport kXML-RPC, Heiko Milke |
| Next by Thread: | usage of ksoap, Micha Eigner |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |