code: public static ByteArrayDiskQueue createFromFile(final long size, final File file, final int bufferSize, final boolean direct) throws IOException {
  		final ByteArrayDiskQueue byteArrayDiskQueue = new ByteArrayDiskQueue(ByteDiskQueue.createFromFile(file, bufferSize, direct));
  		byteArrayDiskQueue.size = size;
  		return byteArrayDiskQueue;
  	}
docs: Creates a new disk-based queue of byte arrays using an existing file.
  
  <p>Note that you have to supply the correct number of byte arrays contained in the dump file of
  the underlying {@link ByteDiskQueue}. Failure to do so will cause unpredictable behaviour.
  
  @param size the number of byte arrays contained in {@code file}.
  @param file the file that will be used to dump the queue on disk.
  @param bufferSize the number of items in the circular buffer (will be possibly decreased so to be a power of two).
  @param direct whether the {@link ByteBuffer} used by this queue should be {@linkplain ByteBuffer#allocateDirect(int) allocated directly}.
  @see ByteDiskQueue#createFromFile(File, int, boolean)