code: protected void openChannel(boolean readHeader) throws FileLockException, IOException {
          logger.debug("[OFile.openChannel] Opening channel for file: " + osFile);
          accessFile = new RandomAccessFile(osFile, (mode == AccessMode.READ_ONLY) ? "r" : "rw");
          accessFile.seek(0);
          channel = accessFile.getChannel();
          lock();
          if (mode == AccessMode.READ_ONLY) {
              headerBuffer = channel.map(FileChannel.MapMode.READ_ONLY, 0, HEADER_SIZE);
          } else {
              headerBuffer = channel.map(FileChannel.MapMode.READ_WRITE, 0, HEADER_SIZE);
          }
          if (readHeader) {
              readHeader();
          }
      }
docs: opens the {@link RandomAccessFile} and the corresponding {@link FileChannel}. Optionally reads the header.
  
  @param should
  the header be read
  @throws IOException