protected Address getAddressForHighlightObject(Object object) {
		if (object instanceof CodeUnit) {
			return ((CodeUnit) object).getMinAddress();
		}
		else if (object instanceof Function) {
			return ((Function) object).getEntryPoint();
		}
		else if (object instanceof Variable) {
			Variable variable = (Variable) object;
			return variable.getFunction().getEntryPoint();
		}
		return null;
	}
A convenience method to examine the highlight object to determine how to get an address
for that object, or null if the object is not of a known type.
@param object The object to examine.
@return the highlight object to determine how to get an address for that object
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/navigation/locationreferences/LocationDescriptor.java