public void populateL10nStrings() {
    AllPropertiesMessageSource allPropertiesMessageSource = new AllPropertiesMessageSource();
    String[] namespaces =
        localizationMessageSources
            .stream()
            .map(PropertiesMessageSource::getNamespace)
            .toArray(String[]::new);
    allPropertiesMessageSource.addMolgenisNamespaces(namespaces);
    localizationPopulator.populateLocalizationStrings(allPropertiesMessageSource);
  }
public void populateL10nStrings ( ) { AllPropertiesMessageSource allPropertiesMessageSource = new AllPropertiesMessageSource ( ) ; String [ ] namespaces = localizationMessageSources . stream ( ) . map ( PropertiesMessageSource :: getNamespace ) . toArray ( String [ ] :: new ) ; allPropertiesMessageSource . addMolgenisNamespaces ( namespaces ) ; localizationPopulator . populateLocalizationStrings ( allPropertiesMessageSource ) ; }
Populates dataService with localization strings from property files on the classpath.

<p>N.B. If you want to add a namespace with a localization resourcebundle, you need to add a
PropertiesMessageSource bean to the spring context for that namespace.