Click or drag to resize

LineRecordReader(Stream, Int64, Int64, Boolean) Constructor

Initializes a new instance of the LineRecordReader class that reads the specified range from the specified stream.

Namespace: Ookii.Jumbo.IO
Assembly: Ookii.Jumbo (in Ookii.Jumbo.dll) Version: 0.3.0+dc1307f20e065bb638e0b73a34cd216f57e486f1
Syntax
public LineRecordReader(
	Stream stream,
	long offset,
	long size,
	bool allowRecordReuse
)

Parameters

stream  Stream
The stream to read from.
offset  Int64
The position in the stream to start reading.
size  Int64
The number of bytes to read from the stream.
allowRecordReuse  Boolean
if the record reader may re-use the same Utf8String instance for every record; if it must create a new instance for every record.
Remarks

The reader will start reading at offset. If offset is larger than zero, the reader will seek ahead to the start of the next record and read from there.

The reader will read a whole number of records until the start of the next record falls after offset + size. Because of this, the reader can read more than size bytes.

The reader will check if stream implements IRecordInputStream with RecordOptions set to DoNotCrossBoundary. If so, if offset falls on a structural boundary the reader will not seek ahead because it knows structural boundaries are record boundaries; if offset + size falls on a structural boundary, the reader is guaranteed to not read beyond offset + size.

See Also