Collection<TypeElement> getImportedTypes() {
		if (imports != null) {
			return imports;
		}

		List<? extends TypeMirror> parameters = getParameterTypes();

		// make the set big enough for all paramters and the return type
		imports = new HashSet<>(parameters.size() + 1);

		addNeededTypes(imports, getReturnType());
		for (TypeMirror param : parameters) {
			addNeededTypes(imports, param);
		}

		return imports;
	}
Gets a collection of all type that need to be imported for this method

@return a collection of types to import
GhidraBuild/BuildFiles/Doclets/src/main/java/ghidra/doclets/typestubs/PythonTypeStubMethod.java