use of org.hl7.gravity.refimpl.sdohexchange.codes.RaceCode in project Gravity-SDOH-Exchange-RI by FHIR.
the class PersonalCharacteristicsService method createRaceBundleFactory.
private PersonalCharacteristicBundleFactory createRaceBundleFactory(NewPersonalCharacteristicDto dto) {
RaceBundleFactory raceBundleFactory = new RaceBundleFactory(dto.getType(), dto.getMethod());
raceBundleFactory.setMethodDetail(dto.getMethodDetail());
if (dto.getValues() != null) {
raceBundleFactory.setValues(Lists.newArrayList(dto.getValues()).stream().map(RaceCode::fromCode).toArray(RaceCode[]::new));
}
raceBundleFactory.setDetailedValues(dto.getDetailedValues());
raceBundleFactory.setDescription(dto.getDescription());
return raceBundleFactory;
}
Aggregations