code: public void writeCopy(long offset) throws IOException {
          final byte[] data = new byte[sectorCount * sectorSize];
          
          for (int index = 0; index < entries.length; index++) {
              fatType.writeEntry(data, index, entries[index]);
          }
          
          device.write(offset, ByteBuffer.wrap(data));
      }
docs: Write the contents of this FAT to the given device at the given offset.
  
  @param offset the device offset where to write the FAT copy
  @throws IOException on write error