class ConfigurationLocator {

    @SuppressWarnings({"PMD.OnlyOneReturn"})
    public String getConfigurationDirectory() {
        for (String directoryPath : getDirectoriesToSearch()) {
            if (directoryExists(directoryPath)) {
                LOGGER.info("ConfigurationLocator found configuration directory: " + directoryPath);
                return directoryPath;
            }
        }

        return forceConfDirectoryCreation();
    }

    public  ConfigurationLocator();

}