private String[] getExternalInfo(final ExternalLocation[] externalLocations,
			int programVersion) {

		Address latestAddress = (externalLocations[LATEST] != null)
				? externalLocations[LATEST].getExternalSpaceAddress()
				: null;
		Address myAddress =
			(externalLocations[MY] != null) ? externalLocations[MY].getExternalSpaceAddress()
					: null;
		Address originalAddress = (externalLocations[ORIGINAL] != null)
				? externalLocations[ORIGINAL].getExternalSpaceAddress()
				: null;

		String[] info = new String[] { "", "", "", "", "", "", "" };

		String versionName = RESULT_TITLE;
		String externalName = "";
		String externalType = "label";
		String actionString = "Keep";
		ExternalLocation externalLocation = null;
		Program pgm = programs[RESULT];

		switch (programVersion) {
			case HEADER:
				return new String[] { "Option", "Name", "Type", "Address", "DataType", "Source",
					"Function" };
			case LATEST:
				pgm = programs[LATEST];
				versionName = LATEST_TITLE;
				if (latestAddress == null) {
					actionString = "Remove";
					break;
				}
				externalLocation = getExternalLocation(latestAddress, LATEST);
				break;
			case MY:
				pgm = programs[MY];
				versionName = MY_TITLE;
				if (myAddress == null) {
					actionString = "Remove";
					break;
				}
				externalLocation = getExternalLocation(myAddress, MY);
				break;
			case ORIGINAL:
				pgm = programs[ORIGINAL];
				versionName = ORIGINAL_TITLE;
				if (originalAddress == null) {
					actionString = "No";
					break;
				}
				externalLocation = getExternalLocation(originalAddress, ORIGINAL);
				break;
		}

		info[0] = actionString + " '" + versionName + "'.";
		if (externalLocation != null) {
			Symbol symbol = externalLocation.getSymbol();
			externalName = symbol.getName(true);
			if (symbol.getSymbolType() == SymbolType.FUNCTION) {
				externalType = "function";
			}
			Address externalAddress = externalLocation.getAddress();
			DataType dataType = getResultDataType(externalLocation);
			SourceType sourceType = externalLocation.getSource();
			Function function = externalLocation.getFunction();

			info[1] = externalName;
			info[2] = externalType;
			info[3] = DiffUtility.getUserToAddressString(pgm, externalAddress);
			if (dataType != null) {
				info[4] = dataType.getDisplayName();
			}
			info[5] = sourceType.getDisplayString();
			if (function != null) {
				info[6] = function.getPrototypeString(true, true);
			}
		}
		return info;
	}
Removes the indicated external from the result program.
@param sourceProgram the program that is the source of the external location
(Either Latest, My, or Original program.)
@param sourceExternalLocation the external location that indicates which external
is to be removed from the result. (External is from Latest, My, or Original program.)
Ghidra/Features/Base/src/main/java/ghidra/app/merge/listing/ExternalFunctionMerger.java