using Valg.EVA.Skanning.ServicesModel.Internal.SystemSettings;

namespace Valg.EVA.Skanning.ServicesModel.Internal.Validation
{
    public class FillPercentageRangeCheckerFactory
    {
        private readonly ISystemSettingsProvider systemSettings;

        public FillPercentageRangeCheckerFactory(ISystemSettingsProvider systemSettings)
        {
            this.systemSettings = systemSettings;
        }


        public FillPercentageRangeChecker GetGeneralPartyVoteRangeChecker()
        {
            return new FillPercentageRangeChecker(systemSettings.GetGeneralBallotPartyVoteFillPercentageMinimum(), systemSettings.GetGeneralBallotPartyVoteFillPercentageMaximum());
        }

        public FillPercentageRangeChecker GetPersonVoteRangeChecker()
        {
            return new FillPercentageRangeChecker(systemSettings.GetPersonVoteFillPercentageMinimum(), systemSettings.GetPersonVoteFillPercentageMaximum());
        }

        public FillPercentageRangeChecker GetStrikeoutRangeChecker()
        {
            return new FillPercentageRangeChecker(systemSettings.GetStrikeOutFillPercentageMinimum(), systemSettings.GetStrikeOutFillPercentageMaximum());
        }
    }
}
