private bool MappingProperties(GpraDemographicsDto gpraDemographicsDto, GpraDemographics gpraDemographics) { AggregateRoot.ReviseGpraDemographics( new GpraDemographicsSection( GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.BirthDate, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupCentralAmericanIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupCubanIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupDominicanIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupMexicanIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupOtherIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupPuertoRicanIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.EthnicGroupSouthAmericanIndicator, _mappingHelper), gpraDemographicsDto.EthnicGroupSpecificationNote, GpraNonResponseTypeMapper.MapToGpraNonResponseType <GpraPatientGender> (gpraDemographicsDto.GpraPatientGender, _mappingHelper), gpraDemographicsDto.GpraPatientGenderSpecificationNote, GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.HispanicLatinoIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.RaceAlaskaNativeIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.RaceAmericanIndianIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.RaceAsianIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.RaceBlackAfricanAmericanIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType( gpraDemographicsDto.RaceNativeHawaiianOtherPacificIslanderIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.RaceWhiteIndicator, _mappingHelper), GpraNonResponseTypeMapper.MapToGpraNonResponseType(gpraDemographicsDto.VeteranIndicator, _mappingHelper) )); gpraDemographicsDto.Key = AggregateRoot.GpraDemographics.Key; return(true); }
/// <summary> /// Processes the single aggregate. /// </summary> /// <param name="gpraDemographicsDto">The gpra demographics dto.</param> /// <param name="gpraDemographics">The gpra demographics.</param> /// <returns>A <see cref="System.Boolean"/></returns> protected override bool ProcessSingleAggregate(GpraDemographicsDto gpraDemographicsDto, GpraDemographics gpraDemographics) { var propertyMappingResult = MappingProperties(gpraDemographicsDto, gpraDemographics); _mappingResult &= propertyMappingResult; return(_mappingResult); }