class EmrDaoImpl implements EmrDao {

    protected List<Configuration> getConfigurations(List<EmrClusterDefinitionConfiguration> emrClusterDefinitionConfigurations)
    {
        List<Configuration> configurations = null;

        if (!CollectionUtils.isEmpty(emrClusterDefinitionConfigurations))
        {
            configurations = new ArrayList<>();

            for (EmrClusterDefinitionConfiguration emrClusterDefinitionConfiguration : emrClusterDefinitionConfigurations)
            {
                if (emrClusterDefinitionConfiguration != null)
                {
                    Configuration configuration = new Configuration();
                    configuration.setClassification(emrClusterDefinitionConfiguration.getClassification());
                    configuration.setConfigurations(getConfigurations(emrClusterDefinitionConfiguration.getConfigurations()));
                    configuration.setProperties(getMap(emrClusterDefinitionConfiguration.getProperties()));

                    configurations.add(configuration);
                }
            }
        }

        return configurations;
    }

}