public synchronized LocalManagedBufferFile getSaveFile(TaskMonitor monitor)
			throws IOException, CancelledException {
		if (saveFile != null) {
			throw new IOException("Save already in progress");
		}
		waitForPreSave(monitor);
		saveFile = preSaveFile;
		preSaveFile = null;
		if (saveFile != null) {
			if (getBufferCount() != saveFile.getBufferCount()) {
				throw new AssertException();
			}
			File vfile = bfMgr.getVersionFile(version);
			if (vfile != null) {
				// Records changes made to pre-save file for reverse reconstruction
				// If vfile already exists, modifications will be added to it.
				saveFile.versionOutFile = new VersionFile(this, saveFile, vfile);
			}

			File mFile = bfMgr.getChangeMapFile();
			if (mFile != null) {
				// Tracks buffers written since checkout
				// If mfile already exists, modifications will be added to it.
				saveFile.changeMap = new ChangeMapFile(mFile, this, saveFile);
			}

			File changeFile = bfMgr.getChangeDataFile(version);
			if (changeFile != null) {
				changeFile =
					new File(changeFile.getParentFile(), changeFile.getName() + TEMP_FILE_EXT);
				changeFile.delete();
				saveChangeFile = new LocalBufferFile(changeFile, getBufferSize());
			}
		}
		return saveFile;
	}
Returns a Save file if available.  Returns null if
a save can not be performed.  This method may block for an extended
period of time if the pre-save process has not already completed.
This method does not accept a monitor since a remote TaskMonitor does
not yet exist.
@param monitor optional monitor for canceling pre-save (may be null)
@throws IOException if an I/O error occurs
@throws CancelledException if monitor specified and pre-save cancelled
Ghidra/Framework/DB/src/main/java/db/buffers/LocalManagedBufferFile.java