private Folder addFolderToIndexIfMissing(String folderPath)
			throws IOException, NotFoundException {

		if (SEPARATOR.equals(folderPath)) {
			return rootFolder;
		}

		int index = folderPath.lastIndexOf(SEPARATOR);
		String name = folderPath.substring(index + 1);
		String parentPath = index == 0 ? SEPARATOR : folderPath.substring(0, index);

		Folder parent = getFolder(parentPath, GetFolderOption.CREATE_ALL);
		Folder folder = parent.folders.get(name);
		if (folder != null) {
			return folder;
		}
		folder = new Folder();
		folder.parent = parent;
		folder.name = name;
		parent.folders.put(name, folder);
		indexJournal.addFolder(folderPath);
		return folder;
	}
Add folder to index during rebuild if missing
NOTE: indexJournal must already open'ed by caller
@param folderPath
@return
@throws IOException
@throws NotFoundException
Ghidra/Framework/FileSystem/src/main/java/ghidra/framework/store/local/IndexedLocalFileSystem.java