Parsing Exceptions

32 views
Skip to first unread message

D3xter

unread,
Mar 2, 2012, 8:36:01 AM3/2/12
to CAP Library
Hey Guys,

I've tried to parse several cap-alerts without any success.
I get different Exceptions while parsing from an URI or from a xml-
file:

Parsing directly via an URl-Inputstream:

Exception in thread "main" java.lang.RuntimeException:
java.io.IOException: Resetting to an invalid mark
at
com.google.publicalerts.cap.CapXmlParser.parseFrom(CapXmlParser.java:
187)

Parsing the same alert from an xml-file:

Exception in thread "main" java.lang.RuntimeException:
java.io.IOException: reset() not supported


I'd appreciate any hints or solutions for my problem.

D3xter

Steve Hakusa

unread,
Mar 2, 2012, 9:19:56 AM3/2/12
to cap-libra...@googlegroups.com
Hi,

What input stream are you using exactly?  Can you try wrapping it in a BufferedInputStream?

Steve

Steve Hakusa

unread,
Mar 2, 2012, 9:22:15 AM3/2/12
to cap-libra...@googlegroups.com
Ah, ok I see you also filed http://code.google.com/p/cap-library/issues/detail?id=27  Sorry I didn't notice this.  I'll reply to the bug.

Steve
Reply all
Reply to author
Forward
0 new messages