@Test public void orikaMapperFactoryBuilder() { assertThat(orikaMapperFactoryBuilder) .isPresent() .hasValueSatisfying(value -> assertThat(value) .hasFieldOrPropertyWithValue("useBuiltinConverters", true) .hasFieldOrPropertyWithValue("useAutoMapping", true) .hasFieldOrPropertyWithValue("mapNulls", true) .hasFieldOrPropertyWithValue("dumpStateOnException", false) .hasFieldOrPropertyWithValue("favorExtension", false) .hasFieldOrPropertyWithValue("captureFieldContext", false) ); }
@ConditionalOnMissingBean @Bean public MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder() { DefaultMapperFactory.Builder orikaMapperFactoryBuilder = new DefaultMapperFactory.Builder(); if (orikaProperties.getUseBuiltinConverters() != null) { orikaMapperFactoryBuilder.useBuiltinConverters(orikaProperties.getUseBuiltinConverters()); } if (orikaProperties.getUseAutoMapping() != null) { orikaMapperFactoryBuilder.useAutoMapping(orikaProperties.getUseAutoMapping()); } if (orikaProperties.getMapNulls() != null) { orikaMapperFactoryBuilder.mapNulls(orikaProperties.getMapNulls()); } if (orikaProperties.getDumpStateOnException() != null) { orikaMapperFactoryBuilder.dumpStateOnException(orikaProperties.getDumpStateOnException()); } if (orikaProperties.getFavorExtension() != null) { orikaMapperFactoryBuilder.favorExtension(orikaProperties.getFavorExtension()); } if (orikaProperties.getCaptureFieldContext() != null) { orikaMapperFactoryBuilder.captureFieldContext(orikaProperties.getCaptureFieldContext()); } orikaMapperFactoryBuilderConfigurers .orElseGet(Collections::emptyList) .forEach(configurer -> configurer.configure(orikaMapperFactoryBuilder)); log.debug("Created a MapperFactoryBuilder: [{}]", orikaMapperFactoryBuilder); return orikaMapperFactoryBuilder; }
OrikaAutoConfiguration { @ConditionalOnMissingBean @Bean public MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder() { DefaultMapperFactory.Builder orikaMapperFactoryBuilder = new DefaultMapperFactory.Builder(); if (orikaProperties.getUseBuiltinConverters() != null) { orikaMapperFactoryBuilder.useBuiltinConverters(orikaProperties.getUseBuiltinConverters()); } if (orikaProperties.getUseAutoMapping() != null) { orikaMapperFactoryBuilder.useAutoMapping(orikaProperties.getUseAutoMapping()); } if (orikaProperties.getMapNulls() != null) { orikaMapperFactoryBuilder.mapNulls(orikaProperties.getMapNulls()); } if (orikaProperties.getDumpStateOnException() != null) { orikaMapperFactoryBuilder.dumpStateOnException(orikaProperties.getDumpStateOnException()); } if (orikaProperties.getFavorExtension() != null) { orikaMapperFactoryBuilder.favorExtension(orikaProperties.getFavorExtension()); } if (orikaProperties.getCaptureFieldContext() != null) { orikaMapperFactoryBuilder.captureFieldContext(orikaProperties.getCaptureFieldContext()); } orikaMapperFactoryBuilderConfigurers .orElseGet(Collections::emptyList) .forEach(configurer -> configurer.configure(orikaMapperFactoryBuilder)); log.debug("Created a MapperFactoryBuilder: [{}]", orikaMapperFactoryBuilder); return orikaMapperFactoryBuilder; } }
OrikaAutoConfiguration { @ConditionalOnMissingBean @Bean public MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder() { DefaultMapperFactory.Builder orikaMapperFactoryBuilder = new DefaultMapperFactory.Builder(); if (orikaProperties.getUseBuiltinConverters() != null) { orikaMapperFactoryBuilder.useBuiltinConverters(orikaProperties.getUseBuiltinConverters()); } if (orikaProperties.getUseAutoMapping() != null) { orikaMapperFactoryBuilder.useAutoMapping(orikaProperties.getUseAutoMapping()); } if (orikaProperties.getMapNulls() != null) { orikaMapperFactoryBuilder.mapNulls(orikaProperties.getMapNulls()); } if (orikaProperties.getDumpStateOnException() != null) { orikaMapperFactoryBuilder.dumpStateOnException(orikaProperties.getDumpStateOnException()); } if (orikaProperties.getFavorExtension() != null) { orikaMapperFactoryBuilder.favorExtension(orikaProperties.getFavorExtension()); } if (orikaProperties.getCaptureFieldContext() != null) { orikaMapperFactoryBuilder.captureFieldContext(orikaProperties.getCaptureFieldContext()); } orikaMapperFactoryBuilderConfigurers .orElseGet(Collections::emptyList) .forEach(configurer -> configurer.configure(orikaMapperFactoryBuilder)); log.debug("Created a MapperFactoryBuilder: [{}]", orikaMapperFactoryBuilder); return orikaMapperFactoryBuilder; }  }
OrikaAutoConfiguration { @ConditionalOnMissingBean @Bean public MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder() { DefaultMapperFactory.Builder orikaMapperFactoryBuilder = new DefaultMapperFactory.Builder(); if (orikaProperties.getUseBuiltinConverters() != null) { orikaMapperFactoryBuilder.useBuiltinConverters(orikaProperties.getUseBuiltinConverters()); } if (orikaProperties.getUseAutoMapping() != null) { orikaMapperFactoryBuilder.useAutoMapping(orikaProperties.getUseAutoMapping()); } if (orikaProperties.getMapNulls() != null) { orikaMapperFactoryBuilder.mapNulls(orikaProperties.getMapNulls()); } if (orikaProperties.getDumpStateOnException() != null) { orikaMapperFactoryBuilder.dumpStateOnException(orikaProperties.getDumpStateOnException()); } if (orikaProperties.getFavorExtension() != null) { orikaMapperFactoryBuilder.favorExtension(orikaProperties.getFavorExtension()); } if (orikaProperties.getCaptureFieldContext() != null) { orikaMapperFactoryBuilder.captureFieldContext(orikaProperties.getCaptureFieldContext()); } orikaMapperFactoryBuilderConfigurers .orElseGet(Collections::emptyList) .forEach(configurer -> configurer.configure(orikaMapperFactoryBuilder)); log.debug("Created a MapperFactoryBuilder: [{}]", orikaMapperFactoryBuilder); return orikaMapperFactoryBuilder; }  @ConditionalOnMissingBean @Bean MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder(); @ConditionalOnMissingBean @Bean MapperFactory orikaMapperFactory(MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder); @ConditionalOnMissingBean @Bean MapperFacade orikaMapperFacade(MapperFactory orikaMapperFactory); }
OrikaAutoConfiguration { @ConditionalOnMissingBean @Bean public MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder() { DefaultMapperFactory.Builder orikaMapperFactoryBuilder = new DefaultMapperFactory.Builder(); if (orikaProperties.getUseBuiltinConverters() != null) { orikaMapperFactoryBuilder.useBuiltinConverters(orikaProperties.getUseBuiltinConverters()); } if (orikaProperties.getUseAutoMapping() != null) { orikaMapperFactoryBuilder.useAutoMapping(orikaProperties.getUseAutoMapping()); } if (orikaProperties.getMapNulls() != null) { orikaMapperFactoryBuilder.mapNulls(orikaProperties.getMapNulls()); } if (orikaProperties.getDumpStateOnException() != null) { orikaMapperFactoryBuilder.dumpStateOnException(orikaProperties.getDumpStateOnException()); } if (orikaProperties.getFavorExtension() != null) { orikaMapperFactoryBuilder.favorExtension(orikaProperties.getFavorExtension()); } if (orikaProperties.getCaptureFieldContext() != null) { orikaMapperFactoryBuilder.captureFieldContext(orikaProperties.getCaptureFieldContext()); } orikaMapperFactoryBuilderConfigurers .orElseGet(Collections::emptyList) .forEach(configurer -> configurer.configure(orikaMapperFactoryBuilder)); log.debug("Created a MapperFactoryBuilder: [{}]", orikaMapperFactoryBuilder); return orikaMapperFactoryBuilder; }  @ConditionalOnMissingBean @Bean MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder(); @ConditionalOnMissingBean @Bean MapperFactory orikaMapperFactory(MapperFactoryBuilder<?, ?> orikaMapperFactoryBuilder); @ConditionalOnMissingBean @Bean MapperFacade orikaMapperFacade(MapperFactory orikaMapperFactory);  }