1 // Copyright 2000-2019 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
2 package com.intellij.psi;
4 import com.intellij.lang.jvm.JvmTypeParametersOwner;
5 import org.jetbrains.annotations.NotNull;
6 import org.jetbrains.annotations.Nullable;
9 * Represents a PSI element (class, interface, method or constructor) which can own a type
14 public interface PsiTypeParameterListOwner extends PsiJvmMember, JvmTypeParametersOwner {
16 * Checks if the element has any type parameters.
18 * @return true if the element has type parameters, false otherwise
20 boolean hasTypeParameters();
23 * Returns the type parameter list for the element.
25 * @return the type parameter list, or null if the element has no type parameters.
28 PsiTypeParameterList getTypeParameterList();
31 * Returns the array of type parameters for the element.
33 * @return the array of type parameters, or an empty array if the element has no type parameters.
37 PsiTypeParameter[] getTypeParameters();