2 ms·
> I do a lot of serialisation. You have no idea how much I'd love to be able to just to `data.set("thing", this.valueEnum?.name())` instead of having to do `dat
by kaba0 3y ago
> I do a lot of serialisation. You have no idea how much I'd love to be able to just to `data.set("thing", this.valueEnum?.name())` instead of having to do `data.set("thing", this.valueEnum == null ? null : this.valueEnum.name())`.
You may be already familiar with this, but mapstruct is a godsend package that easily beats any kind of optional chaining.
- ohgodplsno 3y agoIntroducing annotation processors will never be a godsend.
- kaba0 3y agoDisagree. They should not be the first tool to reach for, but they are basically just safe compile-time macros (mapstruct at least is compile-time only)