public FSRL getFSRL(boolean dirsOk) {
		List<FSBNode> selectedNodes = getSelectedNodes();
		if (selectedNodes.size() != 1) {
			return null;
		}
		FSBNode node = selectedNodes.get(0);
		FSRL fsrl = node.getFSRL();
		if (!dirsOk && node instanceof FSBRootNode fsRootNode &&
			fsRootNode.getContainer() != null) {
			// 'convert' a file system root node back into its container file
			return fsRootNode.getContainer();
		}

		return node.isLeaf() || dirsOk ? fsrl : null;
	}
Returns the {@link FSRL} of the currently selected item, as long as it conforms to
the dirsOk requirement.

@param dirsOk boolean flag, if true the selected item can be either a file or directory
element, if false, it must be a file or the root of a file system that has a container
file
@return FSRL of the single selected item, null if no items selected or more than 1 item
selected
Ghidra/Features/Base/src/main/java/ghidra/plugins/fsbrowser/FSBActionContext.java