Class SegmentedFile

java.lang.Object
org.ojalgo.netio.SegmentedFile
All Implemented Interfaces:
AutoCloseable

public class SegmentedFile extends Object implements AutoCloseable
Divides a large file in segments and then reads those (in parallel) using memory mapped files (memory mapped file segments). Basic usage:
  1. Call newBuilder(File) to get a SegmentedFile.Builder or of(File) to get a SegmentedFile directly with the default settings.
  2. Then for each of the segments obtained from segments(): Call newTextLineReader(Segment) and using that read all the lines.
Multiple threads can be used to read the segments in parallel. Each thread just works on one segment at a time, and there's a new TextLineReader for each segment.