void (@NotNull Language language, @NotNull Set<? super Language> outProcessedLanguages, @NotNull Set<? super String> outDialectIds) { if (outProcessedLanguages.add(language)) { Collection<Language> dialects = language.getTransitiveDialects(); outProcessedLanguages.addAll(dialects); for (Language dialect : dialects) { outDialectIds.add(dialect.getID()); } } }