private PsiClass createArrayClass(LanguageLevel level) {
    String text = JavaFeature.GENERICS.isSufficient(level) ?
                  "public static class __Array__<T> {\n public final int length;\n public T[] clone() {}\n}" :
                  "public static class __Array__{\n public final int length;\n public Object clone() {}\n}";
    PsiClass psiClass = ((PsiExtensibleClass)createClassFromText(text, null)).getOwnInnerClasses().get(0);
    ensureNonWritable(psiClass);
    PsiFile file = psiClass.getContainingFile();
    file.clearCaches();
    PsiUtil.FILE_LANGUAGE_LEVEL_KEY.set(file, level);
    ARRAY_CLASS.set(psiClass, true);
    return psiClass;
  }
private PsiClass createArrayClass(LanguageLevel level)