public final void saveUserDataFile(DomainObject associatedDomainObj, DBHandle userDbh,
			FileSystem userfs,
			TaskMonitor monitor) throws CancelledException, IOException {
		if (userfs.isVersioned()) {
			throw new IllegalArgumentException("User data file-system may not be versioned");
		}
		String associatedContentType = getContentType();
		DomainFile associatedDf = associatedDomainObj.getDomainFile();
		if (associatedDf == null) {
			throw new IllegalStateException("associated " + associatedContentType +
				" file must be saved before user data can be saved");
		}
		String associatedFileID = associatedDf.getFileID();
		if (associatedFileID == null) {
			Msg.error(this, associatedContentType + " '" + associatedDf.getName() +
				"' has not been assigned a file ID, user settings can not be saved!");
			return;
		}
		String path = "/";
		String name = DefaultProjectData.getUserDataFilename(associatedFileID);
		BufferFile bf = null;
		boolean success = false;
		try {
			bf =
				userfs.createDatabase(path, name, FileIDFactory.createFileID(),
					getUserDataContentType(associatedContentType), userDbh.getBufferSize(),
					SystemUtilities.getUserName(), null);
			userDbh.saveAs(bf, true, monitor);
			success = true;
		}
		catch (InvalidNameException e) {
			throw new AssertException("Unexpected Error", e);
		}
		finally {
			if (bf != null && !success) {
				try {
					bf.delete();
				}
				catch (IOException e) {
					// ignore
				}
				abortCreate(userfs, path, name, FolderItem.DEFAULT_CHECKOUT_ID);
			}
		}
	}
Create user data file associated with existing content.
This facilitates the lazy creation of the user data file.
@param associatedDomainObj associated domain object corresponding to this content handler
@param userDbh user data handle
@param userfs private user data filesystem
@param monitor task monitor
@throws IOException if an IO or access error occurs
@throws CancelledException if operation is cancelled by user
Ghidra/Framework/Project/src/main/java/ghidra/framework/data/DBWithUserDataContentHandler.java