Reading a large 2Gb file into with delimiter
<p>I have a file which is 2 gb and more and i need to split it with an delimiter it an export of a db into flat file.</p>

<p>Each record separated by '\u0002\n'
and each field is separated by '\u0001' </p>

<pre><code>FileChannel inChannel = new RandomAccessFile("apps", "r").getChannel();
MappedByteBuffer buffer = inChannel.map(FileChannel.MapMode.READ_ONLY, 0,
                                        inChannel.size());
</code></pre>

<p>The reading works but how can i split into each record ?</p>
