Exemplo n.º 1
0
 /// <summary>
 /// Reads a number of n-tuples from a binary reader to an n-tuple buffer page. This will
 /// attempt to read a much n-tuples as fit on the given page.
 /// </summary>
 /// <param name="reader">The binary reader.</param>
 /// <param name="count">The length of each n-tuple.</param>
 /// <param name="page">The n-tuple buffer page.</param>
 private static void ReadToPage(BinaryReader reader, int count, NPage page)
 {
     page.Clear();
     for (int i = 0; i < page.Size; i++)
     {
         if (reader.BaseStream.Position >= reader.BaseStream.Length)
         {
             break;
         }
         else
         {
             page[i] = Read(reader, count);
         }
     }
 }