function writeCentralFileHeader(writer, file, locator) {
  writer.write(signature.CENTRAL_FILE_HEADER);
  writer.writeUint8(file.version);
  writer.writeUint8(file.madeBy);
  writer.writeCopy(locator.headerStart, locator.headerEnd);
  // TODO extra fields length
  writer.writeUint16(0, true);
  writer.writeUint16(file.comment.length, true);
  writer.writeUint16(file.diskNumberStart, true);
  writer.writeUint16(file.internalFileAttributes, true);
  writer.writeUint32(file.externalFileAttributes, true);
  writer.writeUint32(locator.fileStart, true);
  writer.write(file.centralName);
  // TODO extra fields
  writer.write(file.comment);
}
@param {BufferWriter} writer
@param {FileRecord} file
@param {LocalFileLocator} locator