class ReportInputControlValuesInformationLoader {

    public static ReportInputControlValuesInformation getReportInputControlValuesInformation(
            ListOfValues listOfValues, ResourceBundle resourceBundle, MessageSource messageSource) {

        ReportInputControlValuesInformationImpl valuesInformation = null;

        if (listOfValues != null){
            valuesInformation = new ReportInputControlValuesInformationImpl();

            ListOfValuesItem[] listOfValuesItem = listOfValues.getValues();
            for (ListOfValuesItem valuesItem : listOfValuesItem) {
                ReportInputControlValueInformationImpl valueInformation = new ReportInputControlValueInformationImpl();
                valueInformation.setPromptLabel(InputControlLabelResolver.resolve(valuesItem.getLabel(), resourceBundle, messageSource));
                valueInformation.setDefaultValue(valuesItem.getValue());
                valuesInformation.setInputControlValueInformation(valuesItem.getLabel(), valueInformation);
            }

        }

        return valuesInformation;
    }

}