@Override
	public void actionPerformed(ActionContext context) {
		if (projectName == null) {
			DataTypeManagerHandler archiveManager = plugin.getDataTypeManagerHandler();
			Path path = new Path(archivePath);
			OpenArchiveTask task = new OpenArchiveTask(archiveManager, path);
			new TaskLauncher(task, plugin.getProvider().getComponent());
		}
		else {
			DomainFile df = plugin.getProjectArchiveFile(projectName, archivePath);
			if (df != null) {
				plugin.openArchive(df);
			}
			else {
				Msg.showError(this, null, "Project Archive Open Error",
					"Project data type archive not found: " + getMenuBarData().getMenuItemName());
			}
		}
	}
Class for action to open a recently opened data type archive.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/datamgr/actions/RecentlyOpenedArchiveAction.java