final void pack(byte[] rec) {
		int offs = 0;

		rec[offs++] = (byte) curr;
		rec[offs++] = (byte) (dirty ? 1 : 0);
		rec[offs++] = databaseFormatVersion;

		for (int i = 0; i < 2; i++) {
			Bytes.pack8(rec, offs, root[i].size);
			offs += 8;
			Bytes.pack8(rec, offs, root[i].index);
			offs += 8;
			Bytes.pack8(rec, offs, root[i].shadowIndex);
			offs += 8;
			Bytes.pack8(rec, offs, root[i].usedSize);
			offs += 8;
			Bytes.pack4(rec, offs, root[i].indexSize);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].shadowIndexSize);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].indexUsed);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].freeList);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].bitmapEnd);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].rootObject);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].classDescList);
			offs += 4;
			Bytes.pack4(rec, offs, root[i].bitmapExtent);
			offs += 4;
		}

		Bytes.pack8(rec, offs, transactionId);
		offs += 8;
		Assert.that(offs == sizeof);
	}