class DatabaseTypeSetterFactory {

    public DatabaseTypeSetter get(String databaseType) {
        List<DatabaseTypeSetter> matchingTypeSetters = registeredTypeSetters.stream()
                                                                            .filter(typeSetter -> containsIgnoreCase(databaseType,
                                                                                                                     typeSetter))
                                                                            .collect(Collectors.toList());
        if (matchingTypeSetters.isEmpty()) {
            throw new IllegalStateException(MessageFormat.format("No database type setter is defined for type \"{0}\"", databaseType));
        }

        if (matchingTypeSetters.size() > 1) {
            throw new IllegalStateException(MessageFormat.format("More than one database type setters are defined for type \"{0}\"",
                                                                 databaseType));
        }

        return matchingTypeSetters.get(0);
    }

    public  DatabaseTypeSetterFactory();
    public  DatabaseTypeSetterFactory(List<DatabaseTypeSetter> registeredTypeSetters);

}