Package io.sf.carte.uparser

package io.sf.carte.uparser
A small event parser (microparser).

This package provides two low-level parsers that work with three different token handlers.

TokenProducer is a low-level token producer (parser) that can send events to a TokenHandler or TokenHandler2 handler. It should be used when the error handling only produces runtime (unchecked) exceptions.

On the other hand, TokenProducer3 deals with checked exceptions and can only work with a TokenHandler3 handler.

Most token handlers will report problems through error handlers and throw no checked exceptions, in which case you should use TokenProducer together with a TokenHandler or TokenHandler2. In other use cases your handler may want to throw checked exceptions, and then you must use TokenProducer3 with a TokenHandler3 instead.

As an example, this package includes the CommentRemovalHandler which is to be used with TokenProducer.