mapstruct-idea icon indicating copy to clipboard operation
mapstruct-idea copied to clipboard

IDE Support of `BeanMapping#ignoredTargets`

Open thunderhook opened this issue 1 year ago • 0 comments

When the following PR of https://github.com/mapstruct/mapstruct/issues/3539 is merged:

  • https://github.com/mapstruct/mapstruct/pull/3545

we can also add a support for this kind of ignore list:

@Mapper
public interface BeanMappingIgnoreTargetMapper {

    BeanMappingIgnoreTargetMapper INSTANCE =
            Mappers.getMapper( BeanMappingIgnoreTargetMapper.class );

    @BeanMapping( ignoreTargets = {"nested.flag", "address"} )
    Target convert( Source source );
}

thunderhook avatar Mar 11 '24 21:03 thunderhook