void (StringBuilder text, PsiTypeParameterListOwner typeParameterListOwner, final ClassNameProvider classNameProvider) { if (!typeParameterListOwner.hasTypeParameters()) return; text.append('<'); PsiTypeParameter[] parameters = typeParameterListOwner.getTypeParameters(); final PsiTypeParameterList typeParameterList = typeParameterListOwner.getTypeParameterList(); for (int i = 0; i < parameters.length; i++) { if (i > 0) text.append(", "); PsiTypeParameter parameter = parameters[i]; text.append(parameter.getName()); PsiClassType[] extendsListTypes = parameter.getExtendsListTypes(); if (extendsListTypes.length > 0) { text.append(" extends "); for (int j = 0; j < extendsListTypes.length; j++) { if (j > 0) text.append(" & "); TypeWriter.writeType(text, extendsListTypes[j], typeParameterList, classNameProvider); } } } text.append('>'); }