protected static @Nullable PsiClass createClassInRoot(@NotNull String classFQN,
                                                        @NotNull CreateClassKind classKind,
                                                        @NotNull PsiDirectory rootDir,
                                                        @NotNull PsiElement contextElement,
                                                        @Nullable String superClassName) {
    String packageName = StringUtil.getPackageName(classFQN);
    int lastDot = classFQN.lastIndexOf('.');
    String className = lastDot >= 0 ? classFQN.substring(lastDot + 1) : classFQN;
    PsiDirectory packageDir = getOrCreatePackageDirInRoot(packageName, rootDir);
    if (packageDir == null) return null;

    return CreateFromUsageUtils.createClass(classKind,
                                            packageDir, className, contextElement.getManager(),
                                            contextElement, null, superClassName);
  }
protected static @Nullable PsiClass createClassInRoot(@NotNull String classFQN,
                                                        @NotNull CreateClassKind classKind,
                                                        @NotNull PsiDirectory rootDir,
                                                        @NotNull PsiElement contextElement,
                                                        @Nullable String superClassName)