Introduce dedicated `nullValueIterablePropertyMappingStrategy` and `nullValueMapPropertyMappingStrategy`
#3,387 建立於 2023年9月16日
倉庫指標
- 星標
- (6,640 顆星)
- PR 合併指標
- (平均合併 7天 19小時) (30 天內合併 10 個 PR)
描述
Discussed in https://github.com/mapstruct/mapstruct/discussions/3380
Originally posted by drahkrub September 11, 2023
Since 1.5.0 the nullValueMappingStrategy can be separately defined for Iterables and Maps via nullValueIterableMappingStrategy and nullValueMapMappingStrategy respectively.
It would be nice to do the same for nullValuePropertyMappingStrategy by introducing nullValueIterablePropertyMappingStrategy and nullValueMapPropertyMappingStrategy.
(by the way, I would have found nullValueCollectionMappingStrategy more appropriate than nullValueIterableMappingStrategy)
This would also facilitate the introduction of another NullValuePropertyMappingStrategy, but for that I'll start a new discussion: https://github.com/mapstruct/mapstruct/discussions/3381.