PsiType () { PsiType cachedType = myCachedType; if (cachedType != null) return myCachedType; final GrTypeElement[] typeElements = getTypeElements(); final ArrayList<PsiType> types = new ArrayList<>(); for (GrTypeElement typeElement : typeElements) { types.add(typeElement.getType()); } cachedType = new PsiDisjunctionType(types, getManager()); myCachedType = cachedType; return cachedType; }