On 29/10/13 15:16, Norman Walsh wrote:
Hi folks,
I'm parsing some RDF documents in streaming mode:
...blah blah blah...
try {
ErrorHandler handler = new ParserErrorHandler(fsname);
ParserProfile prof = RiotLib.profile(lang, fsname, handler);
parser.setProfile(prof);
parser.parse();
} catch (Exception e) {
LOG.fatal("Failed to parse: " + origFn);
e.printStackTrace();
parseFailed = true;
}
This has the effect of aborting the parse at the first error. Not
unreasonable, but...
It appears that if I simply load the model into memory, although I get
the same error reported, the "non streaming" loader recovers from the
error and gets more triples.
It does? There is only a streaming parser - when it going into a model,
that is just the destination. You shoudl get an exception from the error.
Can I recover in streaming mode? Ideally, I'd like (modulo duplicates)
to get the same data regardless of whether or not streaming is used.
Do you have a complete, minimal example to show the issue? Tis doesn't
sound right (and what lang?)
Be seeing you,
norm