use of com.intellij.psi.PsiTypeParameter in project intellij-community by JetBrains.
the class AddMethodFix method generateTypeText.
static String generateTypeText(GrTypeDefinition aClass) {
StringBuilder returnType = new StringBuilder(aClass.getName());
final PsiTypeParameter[] typeParameters = aClass.getTypeParameters();
if (typeParameters.length > 0) {
returnType.append('<');
for (PsiTypeParameter typeParameter : typeParameters) {
returnType.append(typeParameter.getName()).append(", ");
}
returnType.replace(returnType.length() - 2, returnType.length(), ">");
}
return returnType.toString();
}
Aggregations