private static void registerSettingsPageProvider(@NotNull Set<? super LanguageCodeStyleSettingsProvider> settingsPagesProviders,
                                                   @NotNull LanguageCodeStyleSettingsProvider provider) {
    try {
      Method
        configMethod = provider.getClass().getMethod("createConfigurable", CodeStyleSettings.class, CodeStyleSettings.class);
      Class<?> declaringClass = configMethod.getDeclaringClass();
      if (!declaringClass.equals(LanguageCodeStyleSettingsProvider.class)) {
        settingsPagesProviders.add(provider);
      }
    }
    catch (NoSuchMethodException e) {
      // Do not add the provider.
    }
  }
private static void registerSettingsPageProvider(@NotNull Set<? super LanguageCodeStyleSettingsProvider> settingsPagesProviders,
                                                   @NotNull LanguageCodeStyleSettingsProvider provider)