private void registerTool(String toolName, PluginTool tool) {
		List<PluginTool> list = namesMap.get(toolName);
		if (list == null) {
			list = new ArrayList<>(5);
			namesMap.put(toolName, list);
		}
		list.add(tool);

		if (list.size() == 1) {
			// first tool, set the default status
			toolStatusMap.put(toolName, ToolSaveStatus.AUTO_SAVE_MODE);
		}

		// make sure tools have unique name
		String instanceName = generateInstanceName(toolName, tool);
		tool.putInstanceName(instanceName);
		tool.addPropertyChangeListener(this);
	}
Registers the new instance of the tool in the namesMap and returns the total number of
running instances of that tool
@param toolName the name of the tool being registers
@param tool the tool being registered
Ghidra/Framework/Project/src/main/java/ghidra/framework/project/tool/ToolManagerImpl.java