org.apache.oro.text.awk
public final class AwkStreamInput extends Object
If you want to perform line by line matches on an input stream, you should use a DataInput or BufferedReader instance in conjunction with one of the PatternMatcher methods taking a String, char[], or PatternMatcherInput as an argument. The DataInput and BufferedReader readLine() methods will likely be implemented as native methods and therefore more efficient than supporting line by line searching within AwkStreamInput.
In the future the programmer will be able to set this class to save all the input it sees so that it can be accessed later. This will avoid having to read a stream more than once for whatever reason.
Since: 1.0
Version: 2.0.8
See Also: AwkMatcher
Constructor Summary | |
---|---|
AwkStreamInput(Reader input, int bufferIncrement)
Creates an AwkStreamInput instance bound to a Reader with a
specified initial buffer size and default buffer increment.
| |
AwkStreamInput(Reader input)
Creates an AwkStreamInput instance bound to a Reader with an
initial buffer size and default buffer increment of 2048 bytes.
|
Method Summary | |
---|---|
boolean | endOfStream() |
Parameters: input The InputStream to associate with the AwkStreamInput instance. bufferIncrement The initial buffer size and the default buffer increment to use when the input buffer has to be increased in size.
Parameters: input The InputStream to associate with the AwkStreamInput instance.