public interface LineProcessor extends Closeable, AutoCloseable
InputReader
usually with help
of the InputProcessors.bridge(LineProcessor)
.
When the implementation is used just by single bridge it does not have to be thread safe.
InputProcessors.bridge(LineProcessor)
,
InputReader
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the processor releasing the resources held by it.
|
void |
processLine(String line)
Processes the line.
|
void |
reset()
Notifies the processor that it should reset its state.
|
void processLine(@NonNull String line)
line
- the line to processvoid reset()
The circumstances when this method is called must be defined by the code using this class.
InputProcessors.bridge(LineProcessor)
delegates any call
to InputProcessor.reset()
to this method.
void close()
close
in interface AutoCloseable
close
in interface Closeable