Conversation
| private TokenChecker checker = null ; | ||
|
|
||
| // The code assumes that errors throw exception and so stop parsing. | ||
| private ErrorHandler errorHandler = new ErrorHandler() { |
There was a problem hiding this comment.
I may be misunderstanding here, but couldn't this be static?
There was a problem hiding this comment.
NM, I see the mutator and accessor below. Still, the default instance could be factored out into a constant, I think.
There was a problem hiding this comment.
Will do. It is stateless though a stateless object is not very expensive to create!
The others are in ErrorHandlerFactory.
It maybe it becomes a parameter to the constructor.
Because letting dubious data through can lead to a lot of support load due to downstream database problems, this PR just adds mechanism and does not enable it. Hence it is keeping the default error handler in-file for now.
There was a problem hiding this comment.
👍 to the scheme (not making it too easy to let cruft through).
Puts in place the structure for warnings not being tokenizer errors.
This is not enabled - it needs testing to see what knock-on effects it has. Ideally, it should be combined with parsers that can do some level of error recovery.
https://issues.apache.org/jira/browse/JENA-1252